websocket and http server: server does not close the bound client socket in many cases
This commit is contained in:
@ -95,6 +95,7 @@ namespace ix
|
||||
}
|
||||
}
|
||||
connectionState->setTerminated();
|
||||
Socket::closeSocket(fd);
|
||||
|
||||
_connectedClientsCount--;
|
||||
}
|
||||
|
@ -93,7 +93,7 @@ namespace ix
|
||||
else
|
||||
{
|
||||
std::stringstream ss;
|
||||
ss << "WebSocketServer::handleConnection() error: "
|
||||
ss << "WebSocketServer::handleConnection() HTTP status: "
|
||||
<< status.http_status
|
||||
<< " error: "
|
||||
<< status.errorStr;
|
||||
@ -111,6 +111,8 @@ namespace ix
|
||||
|
||||
logInfo("WebSocketServer::handleConnection() done");
|
||||
connectionState->setTerminated();
|
||||
|
||||
Socket::closeSocket(fd);
|
||||
}
|
||||
|
||||
std::set<std::shared_ptr<WebSocket>> WebSocketServer::getClients()
|
||||
|
@ -6,4 +6,4 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#define IX_WEBSOCKET_VERSION "6.1.0"
|
||||
#define IX_WEBSOCKET_VERSION "6.2.0"
|
||||
|
Reference in New Issue
Block a user