Bug 712329 - WebSocket should not complain in the console when the document is navigated away, r=smaug
authorAndrea Marchesini <amarchesini@mozilla.com>
Tue, 29 Mar 2016 18:57:36 +0100
changeset 290949 77b2b963de2c9e8172cb5896d938416d30867e8b
parent 290948 52cf294fc0d5597fab5501f7fc4bbc2cd09416a6
child 290950 69fe21c66f7f9edb46c6269fa95d0f0079dab5fa
push id19656
push usergwagner@mozilla.com
push dateMon, 04 Apr 2016 13:43:23 +0000
treeherderb2g-inbound@e99061fde28a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerssmaug
bugs712329
milestone48.0a1
Bug 712329 - WebSocket should not complain in the console when the document is navigated away, r=smaug
dom/base/WebSocket.cpp
--- a/dom/base/WebSocket.cpp
+++ b/dom/base/WebSocket.cpp
@@ -2626,18 +2626,16 @@ WebSocketImpl::CancelInternal()
     return NS_OK;
   }
 
   int64_t readyState = mWebSocket->ReadyState();
   if (readyState == WebSocket::CLOSING || readyState == WebSocket::CLOSED) {
     return NS_OK;
   }
 
-  ConsoleError();
-
   return CloseConnection(nsIWebSocketChannel::CLOSE_GOING_AWAY);
 }
 
 NS_IMETHODIMP
 WebSocketImpl::Suspend()
 {
   AssertIsOnMainThread();
   return NS_ERROR_NOT_IMPLEMENTED;