Fix possible race (BaseUI creation vs x-thread signal-emission)
When a BaseUI is being created, signals can arrive before the _run_loop_thread is running, which can trigger an assert in BaseUI::caller_is_self().
This commit is contained in:
parent
638af32902
commit
e417495505
@ -119,11 +119,12 @@ BaseUI::run ()
|
||||
|
||||
m_context = MainContext::create();
|
||||
_main_loop = MainLoop::create (m_context);
|
||||
attach_request_source ();
|
||||
|
||||
Glib::Threads::Mutex::Lock lm (_run_lock);
|
||||
_run_loop_thread = PBD::Thread::create (boost::bind (&BaseUI::main_thread, this));
|
||||
_running.wait (_run_lock);
|
||||
|
||||
attach_request_source ();
|
||||
}
|
||||
|
||||
void
|
||||
|
Loading…
Reference in New Issue
Block a user