Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 050be725 authored by Jay Aliomer's avatar Jay Aliomer
Browse files

Null point check

When getting a notification by key, we must check if the
mNotificationsByKey map contains the record. not making a null pointer
check resulted in a runtime NullPointerException

Change-Id: I0026a2e74aabf4a6e622c50a1b915599abe4c174
Fix: 142398358
Test: manual test following the steps in the bug
parent b0b28d67
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1985,6 +1985,7 @@ public class NotificationManagerService extends SystemService {
            public void updateAutogroupSummary(String key, boolean needsOngoingFlag) {
                synchronized (mNotificationLock) {
                    NotificationRecord r = mNotificationsByKey.get(key);
                    if (r == null) return;
                    updateAutobundledSummaryFlags(r.getUser().getIdentifier(),
                            r.sbn.getPackageName(), needsOngoingFlag);
                }