summaryrefslogtreecommitdiff
path: root/core/java/android
diff options
context:
space:
mode:
authorAndroid (Google) Code Review <android-gerrit@google.com>2009-08-26 14:03:15 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2009-08-26 14:03:15 -0700
commitd41c577684785eecd3ffa848aafae759e5889731 (patch)
treec6359848b9f7aa8a6d2b8af89330edd860e8043f /core/java/android
parent23b1a470081e6b3c56ada4c43863ca7ed48c3ad2 (diff)
parentb23d4458a91c8e77828fc38ffd81914c2e37d43a (diff)
Merge change 22768 into eclair
* changes: Fix authorization check for Audio Source.
Diffstat (limited to 'core/java/android')
-rw-r--r--core/java/android/server/BluetoothEventLoop.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/core/java/android/server/BluetoothEventLoop.java b/core/java/android/server/BluetoothEventLoop.java
index 34d6d03aabd5..975c2ffc38b7 100644
--- a/core/java/android/server/BluetoothEventLoop.java
+++ b/core/java/android/server/BluetoothEventLoop.java
@@ -430,8 +430,10 @@ class BluetoothEventLoop {
boolean authorized = false;
UUID uuid = UUID.fromString(deviceUuid);
+ // Bluez sends the UUID of the local service being accessed, _not_ the
+ // remote service
if (mBluetoothService.isEnabled() &&
- (BluetoothUuid.isAudioSink(uuid) || BluetoothUuid.isAvrcpTarget(uuid)
+ (BluetoothUuid.isAudioSource(uuid) || BluetoothUuid.isAvrcpTarget(uuid)
|| BluetoothUuid.isAdvAudioDist(uuid))) {
BluetoothA2dp a2dp = new BluetoothA2dp(mContext);
BluetoothDevice device = mAdapter.getRemoteDevice(address);
@@ -444,6 +446,7 @@ class BluetoothEventLoop {
} else {
Log.i(TAG, "Rejecting incoming " + deviceUuid + " connection from " + address);
}
+ log("onAgentAuthorize(" + objectPath + ", " + deviceUuid + ") = " + authorized);
return authorized;
}