commit | 51aeb69dd3ad896dcadab937578e32cafd84c265 | [log] [tgz] |
---|---|---|
author | Andreas Gampe <agampe@google.com> | Mon Dec 14 16:15:38 2015 +0000 |
committer | Android (Google) Code Review <android-gerrit@google.com> | Mon Dec 14 16:15:38 2015 +0000 |
tree | ffec0480a98f7ba35ac6597191067825cad063ff | |
parent | 84515129ed66be629f6a874e63df4506702d7d33 [diff] | |
parent | 1ed71f3722830271602d2d3b2bbd1ba692f75835 [diff] |
Merge "Frameworks/base: Fix Notification code"
diff --git a/core/java/android/service/notification/NotificationListenerService.java b/core/java/android/service/notification/NotificationListenerService.java index 76c63b9..232d4fe 100644 --- a/core/java/android/service/notification/NotificationListenerService.java +++ b/core/java/android/service/notification/NotificationListenerService.java
@@ -713,10 +713,10 @@ createLegacyIconExtras(sbn.getNotification()); maybePopulateRemoteViews(sbn.getNotification()); } catch (IllegalArgumentException e) { - // drop corrupt notification - sbn = null; + // warn and drop corrupt notification Log.w(TAG, "onNotificationPosted: can't rebuild notification from " + sbn.getPackageName()); + sbn = null; } // protect subclass from concurrent modifications of (@link mNotificationKeys}.
diff --git a/services/core/java/com/android/server/notification/NotificationManagerService.java b/services/core/java/com/android/server/notification/NotificationManagerService.java index 1464ea4..e6a48a8 100644 --- a/services/core/java/com/android/server/notification/NotificationManagerService.java +++ b/services/core/java/com/android/server/notification/NotificationManagerService.java
@@ -3686,7 +3686,7 @@ for (int i = 0; i < tokens.length; i++) { String token = tokens[i]; if (token != null) { - token.trim(); + token = token.trim(); } if (TextUtils.isEmpty(token)) { continue;