mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-22 21:24:41 +02:00
ThreadPool#Stop(): discard non-processed queue items
This commit is contained in:
parent
1c8fba182c
commit
797ecd1539
@ -73,6 +73,7 @@ void ThreadPool::Stop()
|
|||||||
for (auto& queue : m_Queues) {
|
for (auto& queue : m_Queues) {
|
||||||
boost::mutex::scoped_lock lock(queue.Mutex);
|
boost::mutex::scoped_lock lock(queue.Mutex);
|
||||||
queue.Stopped = true;
|
queue.Stopped = true;
|
||||||
|
queue.Items.clear();
|
||||||
queue.CV.notify_all();
|
queue.CV.notify_all();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user