Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(830)

Unified Diff: net/websockets/websocket_basic_handshake_stream.h

Issue 105833003: Fail WebSocket channel when handshake fails. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/websockets/websocket_basic_handshake_stream.h
diff --git a/net/websockets/websocket_basic_handshake_stream.h b/net/websockets/websocket_basic_handshake_stream.h
index 69deca2dcf8a1db443d0344f0cdd6652d0e6c0d5..8fb1dc04b3c7c53accaa195664f96e50c51f82eb 100644
--- a/net/websockets/websocket_basic_handshake_stream.h
+++ b/net/websockets/websocket_basic_handshake_stream.h
@@ -71,6 +71,8 @@ class NET_EXPORT_PRIVATE WebSocketBasicHandshakeStream
// For tests only.
void SetWebSocketKeyForTesting(const std::string& key);
+ virtual std::string FailureMessage() const OVERRIDE;
+
private:
// A wrapper for the ReadResponseHeaders callback that checks whether or not
// the connection has been accepted.
@@ -113,6 +115,8 @@ class NET_EXPORT_PRIVATE WebSocketBasicHandshakeStream
// The extension(s) selected by the server.
std::string extensions_;
+ std::string failure_message_;
+
DISALLOW_COPY_AND_ASSIGN(WebSocketBasicHandshakeStream);
};

Powered by Google App Engine
This is Rietveld 408576698