diff options
-rw-r--r-- | android/app/src/com/android/bluetooth/Utils.java | 13 | ||||
-rw-r--r-- | service/src/com/android/server/bluetooth/BtPermissionUtils.java | 3 |
2 files changed, 6 insertions, 10 deletions
diff --git a/android/app/src/com/android/bluetooth/Utils.java b/android/app/src/com/android/bluetooth/Utils.java index ca897af46e..8b8a2c3a3d 100644 --- a/android/app/src/com/android/bluetooth/Utils.java +++ b/android/app/src/com/android/bluetooth/Utils.java @@ -845,10 +845,7 @@ public final class Utils { return true; } - Log.e( - TAG, - "Permission denial: Need ACCESS_COARSE_LOCATION " - + "permission to get scan results"); + Log.e(TAG, "Need ACCESS_COARSE_LOCATION permission for " + currentAttribution); return false; } @@ -889,8 +886,8 @@ public final class Utils { Log.e( TAG, - "Permission denial: Need ACCESS_COARSE_LOCATION or ACCESS_FINE_LOCATION" - + "permission to get scan results"); + "Need ACCESS_COARSE_LOCATION or ACCESS_FINE_LOCATION permission for " + + currentAttribution); return false; } @@ -920,9 +917,7 @@ public final class Utils { return true; } - Log.e( - TAG, - "Permission denial: Need ACCESS_FINE_LOCATION " + "permission to get scan results"); + Log.e(TAG, "Need ACCESS_FINE_LOCATION permission for " + currentAttribution); return false; } diff --git a/service/src/com/android/server/bluetooth/BtPermissionUtils.java b/service/src/com/android/server/bluetooth/BtPermissionUtils.java index b9e736b0f8..bdfbc9f304 100644 --- a/service/src/com/android/server/bluetooth/BtPermissionUtils.java +++ b/service/src/com/android/server/bluetooth/BtPermissionUtils.java @@ -96,7 +96,8 @@ class BtPermissionUtils { return true; } - final String msg = "Need " + permission + " permission for " + source + ": " + message; + final String msg = + "Need " + permission + " permission for " + currentSource + ": " + message; if (result == PERMISSION_HARD_DENIED) { throw new SecurityException(msg); } |