ThreadPool#Stop(): discard non-processed queue items

This commit is contained in:
Alexander A. Klimov 2018-12-03 16:38:52 +01:00
parent 7b39591c6b
commit 30e6d0f809
1 changed files with 1 additions and 0 deletions

View File

@ -73,6 +73,7 @@ void ThreadPool::Stop()
for (auto& queue : m_Queues) {
boost::mutex::scoped_lock lock(queue.Mutex);
queue.Stopped = true;
queue.Items.clear();
queue.CV.notify_all();
}