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

Commit 4aae54cf authored by Jaikumar Ganesh's avatar Jaikumar Ganesh
Browse files

Don't allow connection to profiles in TURNING_OFF state.

A similar change will be made for other profiles.
Bug: 2577713

Dr No: jsh/eastham

Change-Id: Ifca0fbb108e705acefbaeabff07fad83c08f7baa
parent fede9aed
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -313,6 +313,8 @@ public class BluetoothA2dpService extends IBluetoothA2dp.Stub {
                                                "Need BLUETOOTH_ADMIN permission");
        if (DBG) log("connectSink(" + device + ")");

        if (!mBluetoothService.isEnabled()) return false;

        // ignore if there are any active sinks
        if (lookupSinksMatchingStates(new int[] {
                BluetoothA2dp.STATE_CONNECTING,