am 8b283df9
: am b6b4f171
: Merge "Change getName and getAddress permission to BLUETOOTH" into jb-mr1.1-dev
* commit '8b283df989f9b8b71797f9feaeb15cb012ab3190': Change getName and getAddress permission to BLUETOOTH
This commit is contained in:
@ -513,8 +513,8 @@ class BluetoothManagerService extends IBluetoothManager.Stub {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
public String getAddress() {
|
public String getAddress() {
|
||||||
mContext.enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM,
|
mContext.enforceCallingOrSelfPermission(BLUETOOTH_PERM,
|
||||||
"Need BLUETOOTH ADMIN permission");
|
"Need BLUETOOTH permission");
|
||||||
|
|
||||||
if ((Binder.getCallingUid() != Process.SYSTEM_UID) &&
|
if ((Binder.getCallingUid() != Process.SYSTEM_UID) &&
|
||||||
(!checkIfCallerIsForegroundUser())) {
|
(!checkIfCallerIsForegroundUser())) {
|
||||||
@ -538,8 +538,8 @@ class BluetoothManagerService extends IBluetoothManager.Stub {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public String getName() {
|
public String getName() {
|
||||||
mContext.enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM,
|
mContext.enforceCallingOrSelfPermission(BLUETOOTH_PERM,
|
||||||
"Need BLUETOOTH ADMIN permission");
|
"Need BLUETOOTH permission");
|
||||||
|
|
||||||
if ((Binder.getCallingUid() != Process.SYSTEM_UID) &&
|
if ((Binder.getCallingUid() != Process.SYSTEM_UID) &&
|
||||||
(!checkIfCallerIsForegroundUser())) {
|
(!checkIfCallerIsForegroundUser())) {
|
||||||
|
Reference in New Issue
Block a user