]> granicus.if.org Git - icinga2/commitdiff
Added missing lock() call.
authorGunnar Beutner <gunnar.beutner@netways.de>
Thu, 14 Feb 2013 17:48:31 +0000 (18:48 +0100)
committerGunnar Beutner <gunnar.beutner@netways.de>
Thu, 14 Feb 2013 17:48:31 +0000 (18:48 +0100)
lib/base/event.cpp

index b536ebea416cbf38c3bc3cc7b83bbf22dfa1a9a7..37476b464695a08e0b7f1b6328139407e5916fea 100644 (file)
@@ -52,8 +52,11 @@ void Event::ProcessEvents(millisec timeout)
                boost::mutex::scoped_lock lock(m_Mutex);
 
                while (m_Events.empty()) {
-                       if (!m_EventAvailable.timed_wait(lock, timeout))
+                       if (!m_EventAvailable.timed_wait(lock, timeout)) {
+                               Application::GetMutex().lock();
+
                                return;
+                       }
                }
 
                events.swap(m_Events);