mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-02 09:01:50 -05:00
data-loop: call pw_loop_invoke directly
The loop invoke method will already call the function directly when the thread has been stopped and will also make sure that pending items are flushed first. See #2631
This commit is contained in:
parent
9d5f565682
commit
32cf5f312b
1 changed files with 1 additions and 6 deletions
|
|
@ -274,12 +274,7 @@ int pw_data_loop_invoke(struct pw_data_loop *loop,
|
|||
spa_invoke_func_t func, uint32_t seq, const void *data, size_t size,
|
||||
bool block, void *user_data)
|
||||
{
|
||||
int res;
|
||||
if (loop->running)
|
||||
res = pw_loop_invoke(loop->loop, func, seq, data, size, block, user_data);
|
||||
else
|
||||
res = func(loop->loop->loop, false, seq, data, size, user_data);
|
||||
return res;
|
||||
return pw_loop_invoke(loop->loop, func, seq, data, size, block, user_data);
|
||||
}
|
||||
|
||||
/** Set a thread utils implementation.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue