Commit 3ea7d861 authored by Ajay Panicker's avatar Ajay Panicker Committed by android-build-merger
Browse files

Fix setPairingConfirmation permissions issue (1/2) am: df3304a3

am: f8a47ce8

Change-Id: Ia73de9a88d22342fe27f5f1e965cc76b088a7a0d
parents 7b0ed70c f8a47ce8
......@@ -1776,8 +1776,8 @@ public class AdapterService extends Service {
}
boolean setPairingConfirmation(BluetoothDevice device, boolean accept) {
enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM,
"Need BLUETOOTH ADMIN permission");
enforceCallingOrSelfPermission(BLUETOOTH_PRIVILEGED,
"Need BLUETOOTH PRIVILEGED permission");
DeviceProperties deviceProp = mRemoteDevices.getDeviceProperties(device);
if (deviceProp == null || deviceProp.getBondState() != BluetoothDevice.BOND_BONDING) {
return false;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment