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

Commit f4e160a0 authored by Casper Bonde's avatar Casper Bonde Committed by Android Git Automerger
Browse files

am ad4143a0: Fix for MAP/PBAP: Race-condition when requesting authorization from Settings app

* commit 'ad4143a0':
  Fix for MAP/PBAP: Race-condition when requesting authorization from Settings app
parents b01e167e ad4143a0
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -405,8 +405,9 @@ public class BluetoothMapService extends ProfileService {
                        intent.putExtra(BluetoothDevice.EXTRA_ACCESS_REQUEST_TYPE,
                                        BluetoothDevice.REQUEST_TYPE_MESSAGE_ACCESS);
                        intent.putExtra(BluetoothDevice.EXTRA_DEVICE, mRemoteDevice);
                        sendBroadcast(intent, BLUETOOTH_ADMIN_PERM);

                        isWaitingAuthorization = true;
                        sendBroadcast(intent, BLUETOOTH_ADMIN_PERM);

                        if (DEBUG) Log.d(TAG, "waiting for authorization for connection from: "
                                + sRemoteDeviceName);
+2 −1
Original line number Diff line number Diff line
@@ -586,8 +586,9 @@ public class BluetoothPbapService extends Service {
                        intent.putExtra(BluetoothDevice.EXTRA_PACKAGE_NAME, getPackageName());
                        intent.putExtra(BluetoothDevice.EXTRA_CLASS_NAME,
                                        BluetoothPbapReceiver.class.getName());
                        sendBroadcast(intent, BLUETOOTH_ADMIN_PERM);

                        isWaitingAuthorization = true;
                        sendBroadcast(intent, BLUETOOTH_ADMIN_PERM);

                        if (VERBOSE) Log.v(TAG, "waiting for authorization for connection from: "
                                + sRemoteDeviceName);