WorkQueueThread: Fix WaitForCompletion
This commit is contained in:
parent
9186050daa
commit
9d422d14d5
|
@ -124,7 +124,7 @@ public:
|
||||||
if (m_idle && !m_cancelling.load())
|
if (m_idle && !m_cancelling.load())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
m_wait_cond_var.wait(lg, [&] { return m_idle && m_cancelling.load(); });
|
m_wait_cond_var.wait(lg, [&] { return m_idle && !m_cancelling; });
|
||||||
}
|
}
|
||||||
|
|
||||||
// If the worker polls IsCanceling(), it can abort its work when Cancelling
|
// If the worker polls IsCanceling(), it can abort its work when Cancelling
|
||||||
|
|
Loading…
Reference in New Issue