diff options
author | Amith Yamasani <yamasani@google.com> | 2015-07-11 02:27:31 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2015-07-11 02:27:33 +0000 |
commit | 5449ee078620255ce9bea60c0a4dbece36e6acf9 (patch) | |
tree | 17ff0b28617b88e9b78030ddb123f9802c71db17 /packages/SystemUI/src | |
parent | 233bd3ceffbe247b5230f2832ad63c6cf1d9ed13 (diff) | |
parent | 76495678a4e685f031f532aa8c8e902f54cb5624 (diff) | |
download | frameworks_base-5449ee078620255ce9bea60c0a4dbece36e6acf9.zip frameworks_base-5449ee078620255ce9bea60c0a4dbece36e6acf9.tar.gz frameworks_base-5449ee078620255ce9bea60c0a4dbece36e6acf9.tar.bz2 |
Merge "Avoid IPC call with an empty array" into mnc-dev
Diffstat (limited to 'packages/SystemUI/src')
-rw-r--r-- | packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java index 2f5c6e1..891cc73 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java @@ -3033,11 +3033,14 @@ public class PhoneStatusBar extends BaseStatusBar implements DemoMode, } final int N = newlyVisible.size(); - String[] newlyVisibleKeyAr = new String[N]; - for (int i = 0; i < N; i++) { - newlyVisibleKeyAr[i] = newlyVisibleAr[i].key; + if (N > 0) { + String[] newlyVisibleKeyAr = new String[N]; + for (int i = 0; i < N; i++) { + newlyVisibleKeyAr[i] = newlyVisibleAr[i].key; + } + + setNotificationsShown(newlyVisibleKeyAr); } - setNotificationsShown(newlyVisibleKeyAr); } // State logging |