wsd/LOOLWSD.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-)
New commits: commit 51a54496c769e50a16bcc2c9ae8f6d179077a8bc Author: Jan Holesovsky <ke...@collabora.com> Date: Thu Mar 2 19:39:03 2017 +0100 nb: No need to construct a new WebSocketHandler here. Change-Id: I91bdc71732cd54266a2a3f8c751b09e22b7c83a4 diff --git a/wsd/LOOLWSD.cpp b/wsd/LOOLWSD.cpp index 9229168..9c50e25 100644 --- a/wsd/LOOLWSD.cpp +++ b/wsd/LOOLWSD.cpp @@ -3205,8 +3205,6 @@ private: LOG_CHECK_RET(docBroker && "Null DocumentBroker instance", ); const auto docKey = docBroker->getDocKey(); - WebSocketHandler ws; - ws.onConnect(_socket); try { // Connection terminated. Destroy session. @@ -3244,7 +3242,7 @@ private: LOG_ERR("Error in client request handler: " << exc.toString()); const std::string status = "error: cmd=internal kind=unauthorized"; LOG_TRC("Sending to Client [" << status << "]."); - ws.sendFrame(status); + _clientSession->sendFrame(status); } catch (const std::exception& exc) { @@ -3258,14 +3256,14 @@ private: LOG_TRC("Normal close handshake."); // Client initiated close handshake // respond with close frame - ws.shutdown(); + _clientSession->shutdown(); } else if (!SigUtil::isShuttingDown()) { // something wrong, with internal exceptions LOG_TRC("Abnormal close handshake."); _clientSession->closeFrame(); - ws.shutdown(WebSocketHandler::StatusCodes::ENDPOINT_GOING_AWAY); + _clientSession->shutdown(WebSocketHandler::StatusCodes::ENDPOINT_GOING_AWAY); } else { _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits