[Libreoffice-commits] online.git: Branch 'private/Ashod/nonblocking' - wsd/LOOLWSD.cpp
Jan Holesovsky
kendy at collabora.com
Thu Mar 2 18:42:22 UTC 2017
wsd/LOOLWSD.cpp | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
New commits:
commit 51a54496c769e50a16bcc2c9ae8f6d179077a8bc
Author: Jan Holesovsky <kendy at 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
{
More information about the Libreoffice-commits
mailing list