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

Commit ad4e3c5d authored by Gurpreet Ghai's avatar Gurpreet Ghai Committed by android-build-merger
Browse files

Merge "Fix ANR due to long wait for synchronization lock"

am: 9193014e

Change-Id: Ic41c34a5701658aa328a83267ad3c818d55bd522
parents 18019880 9193014e
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
@@ -194,8 +194,13 @@ public class LocalBluetoothAdapter {
        return mState;
    }

    synchronized void setBluetoothStateInt(int state) {
    void setBluetoothStateInt(int state) {
        synchronized(this) {
            if (mState == state) {
                return;
            }
            mState = state;
        }

        if (state == BluetoothAdapter.STATE_ON) {
            // if mProfileManager hasn't been constructed yet, it will