summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--net/websockets/websocket.cc2
-rw-r--r--net/websockets/websocket_unittest.cc16
2 files changed, 9 insertions, 9 deletions
diff --git a/net/websockets/websocket.cc b/net/websockets/websocket.cc
index 2d7169d..0ccce69 100644
--- a/net/websockets/websocket.cc
+++ b/net/websockets/websocket.cc
@@ -17,7 +17,7 @@ static const int kWebSocketPort = 80;
static const int kSecureWebSocketPort = 443;
static const char kServerHandshakeHeader[] =
- "HTTP/1.1 101 Web Socket Protocol\r\n";
+ "HTTP/1.1 101 Web Socket Protocol Handshake\r\n";
static const size_t kServerHandshakeHeaderLength =
sizeof(kServerHandshakeHeader) - 1;
diff --git a/net/websockets/websocket_unittest.cc b/net/websockets/websocket_unittest.cc
index 907f62a..6157271 100644
--- a/net/websockets/websocket_unittest.cc
+++ b/net/websockets/websocket_unittest.cc
@@ -128,7 +128,7 @@ class WebSocketTest : public PlatformTest {
TEST_F(WebSocketTest, Connect) {
MockClientSocketFactory mock_socket_factory;
MockRead data_reads[] = {
- MockRead("HTTP/1.1 101 Web Socket Protocol\r\n"
+ MockRead("HTTP/1.1 101 Web Socket Protocol Handshake\r\n"
"Upgrade: WebSocket\r\n"
"Connection: Upgrade\r\n"
"WebSocket-Origin: http://example.com\r\n"
@@ -187,13 +187,13 @@ TEST_F(WebSocketTest, ServerSentData) {
static const char kFrame[] = "\x00Hello\xff";
static const int kFrameLen = sizeof(kFrame) - 1;
MockRead data_reads[] = {
- MockRead("HTTP/1.1 101 Web Socket Protocol\r\n"
- "Upgrade: WebSocket\r\n"
- "Connection: Upgrade\r\n"
- "WebSocket-Origin: http://example.com\r\n"
- "WebSocket-Location: ws://example.com/demo\r\n"
- "WebSocket-Protocol: sample\r\n"
- "\r\n"),
+ MockRead("HTTP/1.1 101 Web Socket Protocol Handshake\r\n"
+ "Upgrade: WebSocket\r\n"
+ "Connection: Upgrade\r\n"
+ "WebSocket-Origin: http://example.com\r\n"
+ "WebSocket-Location: ws://example.com/demo\r\n"
+ "WebSocket-Protocol: sample\r\n"
+ "\r\n"),
MockRead(true, kFrame, kFrameLen),
// Server doesn't close the connection after handshake.
MockRead(true, ERR_IO_PENDING),