thread-loop: signal when started

This makes it possible to wait for the thread to have started.
This commit is contained in:
Wim Taymans 2023-07-20 15:29:30 +02:00
parent be9c6b1842
commit 33be898130

View file

@ -282,6 +282,8 @@ static void *do_loop(void *user_data)
pw_log_debug("%p: enter thread", this); pw_log_debug("%p: enter thread", this);
pw_loop_enter(this->loop); pw_loop_enter(this->loop);
pw_thread_loop_signal(this, false);
while (this->running) { while (this->running) {
if ((res = pw_loop_iterate(this->loop, -1)) < 0) { if ((res = pw_loop_iterate(this->loop, -1)) < 0) {
if (res == -EINTR) if (res == -EINTR)