mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-31 22:25:38 -04:00
alsa: first start monitor then enumerate devices
So that we can catch the SOUND_INITIALIZED update between enumerating devices and starting the monitor.This fixes a races in detecting devices. Thanks to Matthias Fend for finding this. Fixes #2046
This commit is contained in:
parent
cec9347864
commit
5b3bc4e80e
1 changed files with 2 additions and 2 deletions
|
|
@ -687,10 +687,10 @@ impl_device_add_listener(void *object, struct spa_hook *listener,
|
|||
|
||||
emit_device_info(this, true);
|
||||
|
||||
if ((res = enum_devices(this)) < 0)
|
||||
if ((res = start_monitor(this)) < 0)
|
||||
return res;
|
||||
|
||||
if ((res = start_monitor(this)) < 0)
|
||||
if ((res = enum_devices(this)) < 0)
|
||||
return res;
|
||||
|
||||
spa_hook_list_join(&this->hooks, &save);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue