Debugging bad notification sorts.
Bug: 16626175 Change-Id: I6cc7ee5f853c846e3aed6f9750e8fb6bc5aed699
This commit is contained in:
committed by
Dan Sandler
parent
256a22663d
commit
41da5ff98f
@@ -1642,7 +1642,23 @@ public class NotificationManagerService extends SystemService {
|
||||
|
||||
applyZenModeLocked(r);
|
||||
|
||||
mRankingHelper.sort(mNotificationList);
|
||||
try {
|
||||
mRankingHelper.sort(mNotificationList);
|
||||
} catch (RuntimeException ex) {
|
||||
// Don't crash the system server if something bad happened.
|
||||
Log.e(TAG, "Extreme badness during notification sort", ex);
|
||||
Log.e(TAG, "Current notification list: ");
|
||||
for (int ii=0; ii < mNotificationList.size(); ii++) {
|
||||
NotificationRecord nr = mNotificationList.get(ii);
|
||||
Log.e(TAG, String.format(
|
||||
" [%d] %s (group %s, rank %d, sortkey %s, proxy %s)",
|
||||
ii, nr, nr.getGroupKey(), nr.getAuthoritativeRank(),
|
||||
nr.getNotification().getSortKey(),
|
||||
nr.getRankingProxy()));
|
||||
}
|
||||
// STOPSHIP: remove once b/16626175 is found
|
||||
throw ex;
|
||||
}
|
||||
|
||||
if (notification.icon != 0) {
|
||||
StatusBarNotification oldSbn = (old != null) ? old.sbn : null;
|
||||
|
||||
Reference in New Issue
Block a user