mirror of
https://github.com/Palakis/obs-websocket.git
synced 2024-08-30 18:12:16 +00:00
Bugfix : deadlock when closing the server
Caused by a non-recursive mutex
This commit is contained in:
parent
3d68b7c9e5
commit
0ff4411abf
@ -35,7 +35,7 @@ WSServer::WSServer(QObject *parent) :
|
||||
QObject(parent),
|
||||
_wsServer(Q_NULLPTR),
|
||||
_clients(),
|
||||
_clMutex(QMutex::NonRecursive)
|
||||
_clMutex(QMutex::Recursive)
|
||||
{
|
||||
_serverThread = new QThread();
|
||||
|
||||
@ -77,8 +77,6 @@ void WSServer::Stop()
|
||||
{
|
||||
pClient->close();
|
||||
}
|
||||
|
||||
qDeleteAll(_clients.begin(), _clients.end());
|
||||
_clMutex.unlock();
|
||||
|
||||
_wsServer->close();
|
||||
|
Loading…
x
Reference in New Issue
Block a user