fixes
This commit is contained in:
		| @@ -272,8 +272,6 @@ namespace ix | ||||
|             // 2. Poll to see if there's any new data available | ||||
|             WebSocketTransport::PollPostTreatment pollPostTreatment = _ws.poll(); | ||||
|  | ||||
|             //if (_stop) return; | ||||
|  | ||||
|             // 3. Dispatch the incoming messages | ||||
|             _ws.dispatch( | ||||
|                 pollPostTreatment, | ||||
|   | ||||
| @@ -43,7 +43,7 @@ namespace ix | ||||
|             client->close(); | ||||
|         } | ||||
|  | ||||
|         //SocketServer::stop(); | ||||
|         SocketServer::stop(); | ||||
|     } | ||||
|  | ||||
|     void WebSocketServer::enablePong() | ||||
|   | ||||
| @@ -333,7 +333,7 @@ namespace ix | ||||
|             _socket->close(); | ||||
|         } | ||||
|  | ||||
|         if (_readyState == CLOSING && closingDelayExceeded()) | ||||
|         if (_readyState == CLOSING /*&& closingDelayExceeded()*/) | ||||
|         { | ||||
|             // close code and reason were set when calling close() | ||||
|             _socket->close(); | ||||
| @@ -928,8 +928,6 @@ namespace ix | ||||
|  | ||||
|         sendCloseFrame(code, reason); | ||||
|  | ||||
|         setReadyState(CLOSING); | ||||
|  | ||||
|         { | ||||
|             std::lock_guard<std::mutex> lock(_closeDataMutex); | ||||
|             _closeCode = code; | ||||
| @@ -941,6 +939,9 @@ namespace ix | ||||
|             std::lock_guard<std::mutex> lock(_closingTimePointMutex); | ||||
|             _closingTimePoint = std::chrono::steady_clock::now(); | ||||
|         } | ||||
|         setReadyState(CLOSING); | ||||
|  | ||||
|         _socket->wakeUpFromPoll(Socket::kSendRequest); | ||||
|     } | ||||
|  | ||||
|     size_t WebSocketTransport::bufferedAmount() const | ||||
|   | ||||
| @@ -35,12 +35,12 @@ set (SOURCES | ||||
| # Some unittest don't work on windows yet | ||||
| if (NOT WIN32) | ||||
|   list(APPEND SOURCES  | ||||
|     #IXWebSocketCloseTest.cpp | ||||
|     IXWebSocketCloseTest.cpp | ||||
|     IXWebSocketServerTest.cpp | ||||
|     #IXWebSocketPingTest.cpp | ||||
|     #IXWebSocketPingTimeoutTest.cpp | ||||
|     #cmd_websocket_chat.cpp | ||||
|     #IXWebSocketTestConnectionDisconnection.cpp | ||||
|     IXWebSocketPingTest.cpp | ||||
|     IXWebSocketPingTimeoutTest.cpp | ||||
|     cmd_websocket_chat.cpp | ||||
|     IXWebSocketTestConnectionDisconnection.cpp | ||||
|   ) | ||||
| endif() | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user