mirror of
https://github.com/wownero/wowlet.git
synced 2026-10-20 00:28:39 +02:00
WebsocketClient: fix potential crash
This commit is contained in:
@@ -117,3 +117,9 @@ void WebsocketClient::onbinaryMessageReceived(const QByteArray &message) {
|
||||
|
||||
emit WSMessage(object);
|
||||
}
|
||||
|
||||
WebsocketClient::~WebsocketClient() {
|
||||
// webSocket may fire QWebSocket::disconnected after WebsocketClient is destroyed
|
||||
// explicitly disconnect to prevent crash
|
||||
webSocket.disconnect();
|
||||
}
|
||||
Reference in New Issue
Block a user