From 4220a1bdc1b8ca5fe5cb300e4b604de3ff105646 Mon Sep 17 00:00:00 2001 From: Nick Pelly <> Date: Tue, 31 Mar 2009 12:05:52 -0700 Subject: [PATCH] AI 143740: Don't clear supported profiles in settings app if getRemoteClass returns error. Also clean up the error codes returned by the framework, so that the settings app can properly detect an error. BUG=1748881 Automated import of CL 143740 --- src/com/android/settings/bluetooth/LocalBluetoothDevice.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/com/android/settings/bluetooth/LocalBluetoothDevice.java b/src/com/android/settings/bluetooth/LocalBluetoothDevice.java index 199a4225baf..86b1d69e3b3 100644 --- a/src/com/android/settings/bluetooth/LocalBluetoothDevice.java +++ b/src/com/android/settings/bluetooth/LocalBluetoothDevice.java @@ -575,8 +575,9 @@ public class LocalBluetoothDevice implements Comparable { */ private void fetchBtClass() { mBtClass = mLocalManager.getBluetoothManager().getRemoteClass(mAddress); - mProfiles.clear(); - LocalBluetoothProfileManager.fill(mBtClass, mProfiles); + if (mBtClass != BluetoothClass.ERROR) { + LocalBluetoothProfileManager.fill(mBtClass, mProfiles); + } } /**