event/Loop: read the "again" flag while holding mutex

This commit is contained in:
Max Kellermann 2014-12-14 14:47:32 +01:00
parent 51464b4317
commit 3c29aa6271

View File

@ -179,9 +179,10 @@ EventLoop::Run()
mutex.lock();
HandleDeferred();
busy = false;
const bool _again = again;
mutex.unlock();
if (again)
if (_again)
/* re-evaluate timers because one of the
IdleMonitors may have added a new
timeout */