refactor: replace RecursiveMutex m_callbacks_mutex with Mutex

In each of the critical sections, only the the guarded variables are
accessed, without any chance that within one section another one is
called.  Hence, we can use an ordinary Mutex instead of RecursiveMutex.
This commit is contained in:
Sebastian Falbesoner 2022-01-14 13:27:41 +01:00
parent 3aa258109e
commit 5574e6ed52

View File

@ -119,7 +119,7 @@ class SingleThreadedSchedulerClient
private:
CScheduler* m_pscheduler;
RecursiveMutex m_callbacks_mutex;
Mutex m_callbacks_mutex;
std::list<std::function<void()>> m_callbacks_pending GUARDED_BY(m_callbacks_mutex);
bool m_are_callbacks_running GUARDED_BY(m_callbacks_mutex) = false;