diff --git a/src/Notifier.cpp b/src/Notifier.cpp index cba61c6f8f..c4c65db3bb 100644 --- a/src/Notifier.cpp +++ b/src/Notifier.cpp @@ -36,8 +36,10 @@ void Notifier::Stop() { void Notifier::ThreadMain() { std::unique_lock lock(m_mutex); while (m_active) { - m_cond.wait(lock); - if (!m_active) continue; + while (m_entry_notifications.empty() && m_conn_notifications.empty()) { + m_cond.wait(lock); + if (!m_active) return; + } // Entry notifications while (!m_entry_notifications.empty()) {