catch nullptr on websocket connections (#4300)

* catch nullptr on websocket connections

* clangify
This commit is contained in:
ebbit1q
2021-04-01 23:34:49 -04:00
committed by GitHub
parent 8e954b10e6
commit b940e17fe7
+3
View File
@@ -1692,6 +1692,9 @@ WebsocketServerSocketInterface::~WebsocketServerSocketInterface()
void WebsocketServerSocketInterface::initConnection(void *_socket)
{
if (_socket == nullptr) {
return;
}
socket = (QWebSocket *)_socket;
socket->setParent(this);
address = socket->peerAddress();