diff --git a/src/scheduler.cpp b/src/scheduler.cpp index 80a210ca7..29f7cee5e 100644 --- a/src/scheduler.cpp +++ b/src/scheduler.cpp @@ -141,6 +141,7 @@ size_t CScheduler::getQueueInfo(boost::chrono::system_clock::time_point &first, } bool CScheduler::AreThreadsServicingQueue() const { + boost::unique_lock lock(newTaskMutex); return nThreadsServicingQueue; }