Fix bitmrc deadlock
This commit is contained in:
parent
b3c0487797
commit
961f2b0a0b
@ -184,8 +184,15 @@ namespace Components
|
|||||||
}
|
}
|
||||||
|
|
||||||
BitMessage::~BitMessage()
|
BitMessage::~BitMessage()
|
||||||
|
{
|
||||||
|
BitMessage::Save();
|
||||||
|
|
||||||
|
// We have to do that in another thread, as sometims the terminating thread already holds the mutex lock...
|
||||||
|
std::thread([&] ()
|
||||||
{
|
{
|
||||||
delete BitMessage::BMClient;
|
delete BitMessage::BMClient;
|
||||||
|
}).join();
|
||||||
|
|
||||||
BitMessage::BMClient = nullptr;
|
BitMessage::BMClient = nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user