Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 62895a67 authored by Nick Pelly's avatar Nick Pelly
Browse files

Fix regression.

When turning off BT while connected to an A2DP/HFP headset we can hit the path

BluetoothHeadsetService.onReceive(BluetoothHeadset.STATE_CHANGED) ->
BluetoothHandsfree.audioOff() ->
BluetoothA2dp.resumeSink() ->
which causes resumeSink() to NPE because mAudioDevices.get() returns null.

It's a race between A2DP marking the device as disconnected, and HFP marking
the device as disconnected.

Fix is to NPE check in resumeSink().

Change-Id: I2782ac8c70ea1678d7de5fcd49bff8e03df36f4e
parent 285f2422
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment