mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
jack: don't call callbacks when deactivating
Set the active state to false right when we start deactivate to make sure that we don't call any callbacks anymore during shutdown. One of the callbacks that might be called is the bufsize of samplerate change callbacks when the node is moved to the dummy driver and this might deadlock any app that doesn't expect this. Fixes #2781
This commit is contained in:
parent
5ae73fccdd
commit
495a227e5e
1 changed files with 3 additions and 6 deletions
|
|
@ -3800,6 +3800,8 @@ int jack_deactivate (jack_client_t *client)
|
|||
return 0;
|
||||
|
||||
pw_thread_loop_lock(c->context.loop);
|
||||
c->active = false;
|
||||
|
||||
pw_data_loop_stop(c->loop);
|
||||
|
||||
pw_client_node_set_active(c->node, false);
|
||||
|
|
@ -3818,12 +3820,7 @@ int jack_deactivate (jack_client_t *client)
|
|||
|
||||
pw_thread_loop_unlock(c->context.loop);
|
||||
|
||||
if (res < 0)
|
||||
return res;
|
||||
|
||||
c->active = false;
|
||||
|
||||
return 0;
|
||||
return res;
|
||||
}
|
||||
|
||||
SPA_EXPORT
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue