[IPC] Better worker cleanup

This commit is contained in:
momo5502 2017-01-29 11:48:42 +01:00
parent 0139465337
commit 67d963a0c8

View File

@ -14,11 +14,10 @@ namespace Utils
Channel::~Channel()
{
{
std::lock_guard<std::mutex> _(this->queueMutex);
std::unique_lock<std::mutex> lock(this->queueMutex);
this->terminateQueue = true;
this->queueEvent.notify_all();
}
lock.unlock();
if (this->queueThread.joinable())
{