diff options
author | loislo@chromium.org <loislo@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-26 16:14:49 +0000 |
---|---|---|
committer | loislo@chromium.org <loislo@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-26 16:14:49 +0000 |
commit | c51ab1223baa573bd74182b6679e89e4e205fa11 (patch) | |
tree | e8de30be404926893a5e36d035f5ee792fa50a1a /net/server/http_server.cc | |
parent | a89e09411e25b190474b01305fb6e562cd2361ba (diff) | |
download | chromium_src-c51ab1223baa573bd74182b6679e89e4e205fa11.zip chromium_src-c51ab1223baa573bd74182b6679e89e4e205fa11.tar.gz chromium_src-c51ab1223baa573bd74182b6679e89e4e205fa11.tar.bz2 |
DevTools: web socket does not expect frames other than text.
BUG=97974
TEST=none
Review URL: http://codereview.chromium.org/8043023
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@102736 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/server/http_server.cc')
-rw-r--r-- | net/server/http_server.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/net/server/http_server.cc b/net/server/http_server.cc index 42d5752..6f2a46b 100644 --- a/net/server/http_server.cc +++ b/net/server/http_server.cc @@ -80,7 +80,9 @@ void HttpServer::Close(int connection_id) if (connection == NULL) return; - connection->DetachSocket(); + // Initiating close from server-side does not lead to the DidClose call. + // Do it manually here. + DidClose(connection->socket_); } // @@ -237,7 +239,8 @@ void HttpServer::DidRead(ListenSocket* socket, if (result == WebSocket::FRAME_INCOMPLETE) break; - if (result == WebSocket::FRAME_ERROR) { + if (result == WebSocket::FRAME_CLOSE || + result == WebSocket::FRAME_ERROR) { Close(connection->id()); break; } |