summaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorJason Monk <jmonk@google.com>2014-12-11 19:28:28 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-12-11 19:28:28 +0000
commit70cf2f72f2e19570d81c1365164313437b38ffd5 (patch)
treedf6e20f436c4734de7e743dbedbbecb9f287a67d /packages
parentcac8662943b28663fefc6e5315a7b9acd514bfdb (diff)
parent7d8ccb41fa3756839597cd28cd5710c1b690e17f (diff)
downloadframeworks_base-70cf2f72f2e19570d81c1365164313437b38ffd5.zip
frameworks_base-70cf2f72f2e19570d81c1365164313437b38ffd5.tar.gz
frameworks_base-70cf2f72f2e19570d81c1365164313437b38ffd5.tar.bz2
am 7d8ccb41: Merge "Fix crash in BluetoothControllerImpl" into lmp-mr1-dev
* commit '7d8ccb41fa3756839597cd28cd5710c1b690e17f': Fix crash in BluetoothControllerImpl
Diffstat (limited to 'packages')
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/policy/BluetoothControllerImpl.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/BluetoothControllerImpl.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/BluetoothControllerImpl.java
index 076cfe2..229c558 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/BluetoothControllerImpl.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/BluetoothControllerImpl.java
@@ -289,9 +289,11 @@ public class BluetoothControllerImpl implements BluetoothController {
.getDevicesMatchingConnectionStates(connectionType);
for (int k = 0; k < devices.size(); k++) {
DeviceInfo info = mDeviceInfo.get(devices.get(k));
- info.connectionState = CONNECTION_STATES[i];
- if (CONNECTION_STATES[i] == BluetoothProfile.STATE_CONNECTED) {
- info.connectedProfiles.put(profile, true);
+ if (info != null) {
+ info.connectionState = CONNECTION_STATES[i];
+ if (CONNECTION_STATES[i] == BluetoothProfile.STATE_CONNECTED) {
+ info.connectedProfiles.put(profile, true);
+ }
}
}
}