mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-06 13:29:56 -05:00
bluetooth: Only remove cards belonging to the device.
Commit f89d64b98e fixed a crash
when disabling adapters. However, now if any device is removed
ofono card is removed, even if it belongs to different device.
Add a check for the device being unlinked to our callback to fix.
Signed-off-by: Juho Hämäläinen <juho.hamalainen@jolla.com>
Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/624>
This commit is contained in:
parent
3e2dacdb38
commit
b1057f1a37
1 changed files with 3 additions and 0 deletions
|
|
@ -250,6 +250,9 @@ static pa_hook_result_t device_unlink_cb(pa_bluetooth_discovery *y, const pa_blu
|
|||
pa_assert(d);
|
||||
pa_assert(card);
|
||||
|
||||
if (d != card->transport->device)
|
||||
return PA_HOOK_OK;
|
||||
|
||||
hf_audio_agent_card_removed(card->backend, card->path);
|
||||
|
||||
return PA_HOOK_OK;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue