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

Commit c5768ce5 authored by Treehugger Robot's avatar Treehugger Robot Committed by Jack He
Browse files

HFP: Fix typo in various permission check messages

Bug: 72830122
Test: make, no functional change
Change-Id: Ie10d7f40fa6dccafc70313328e26291863c5fd64
(cherry picked from commit 6f6f0c0a)
parent d9020c84
Loading
Loading
Loading
Loading
+4 −4
Original line number Original line Diff line number Diff line
@@ -668,7 +668,7 @@ public class HeadsetService extends ProfileService {
    }
    }


    boolean disconnect(BluetoothDevice device) {
    boolean disconnect(BluetoothDevice device) {
        enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM, "Need BLUETOOTH ADMIN permission");
        enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM, "Need BLUETOOTH_ADMIN permission");
        synchronized (mStateMachines) {
        synchronized (mStateMachines) {
            Log.i(TAG, "disconnect: device=" + device);
            Log.i(TAG, "disconnect: device=" + device);
            HeadsetStateMachine stateMachine = mStateMachines.get(device);
            HeadsetStateMachine stateMachine = mStateMachines.get(device);
@@ -946,7 +946,7 @@ public class HeadsetService extends ProfileService {
     * @return the active device or null if no device is active
     * @return the active device or null if no device is active
     */
     */
    public BluetoothDevice getActiveDevice() {
    public BluetoothDevice getActiveDevice() {
        enforceCallingOrSelfPermission(BLUETOOTH_PERM, "Need BLUETOOTH_PERM permission");
        enforceCallingOrSelfPermission(BLUETOOTH_PERM, "Need BLUETOOTH permission");
        synchronized (mStateMachines) {
        synchronized (mStateMachines) {
            return mActiveDevice;
            return mActiveDevice;
        }
        }
@@ -1049,7 +1049,7 @@ public class HeadsetService extends ProfileService {
    }
    }


    boolean startScoUsingVirtualVoiceCall(BluetoothDevice device) {
    boolean startScoUsingVirtualVoiceCall(BluetoothDevice device) {
        enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM, "Need BLUETOOTH permission");
        enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM, "Need BLUETOOTH_ADMIN permission");
        synchronized (mStateMachines) {
        synchronized (mStateMachines) {
            final HeadsetStateMachine stateMachine = mStateMachines.get(device);
            final HeadsetStateMachine stateMachine = mStateMachines.get(device);
            if (stateMachine == null) {
            if (stateMachine == null) {
@@ -1063,7 +1063,7 @@ public class HeadsetService extends ProfileService {
    }
    }


    boolean stopScoUsingVirtualVoiceCall(BluetoothDevice device) {
    boolean stopScoUsingVirtualVoiceCall(BluetoothDevice device) {
        enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM, "Need BLUETOOTH permission");
        enforceCallingOrSelfPermission(BLUETOOTH_ADMIN_PERM, "Need BLUETOOTH_ADMIN permission");
        synchronized (mStateMachines) {
        synchronized (mStateMachines) {
            final HeadsetStateMachine stateMachine = mStateMachines.get(device);
            final HeadsetStateMachine stateMachine = mStateMachines.get(device);
            if (stateMachine == null) {
            if (stateMachine == null) {