Skip to content
Commit efa1a74b authored by Kensuke Matsui's avatar Kensuke Matsui Committed by Selim Cinek
Browse files

Fix NPE which could occur when showing notification guts

SystemUI keeps shown heads-up notification for minimum display time
even if the notification is canceled right after it's posted.

This is intentional behavior but causes inconsistency between
mEntry and mRankingMap in NotificationData.
That inconsistency could cause NPE when showing notification guts.

To avoid this, update an Entry only when the corresponding Ranking
is available.

Fixes: 65567562
Test: manual - long press a missed call notification
               immediately after receiving an incoming call
Test: runtest -x packages/SystemUI/tests/src/com/android/systemui/statusbar/NotificationDataTest.java

Change-Id: I6dc70d8e57efa7af0f23862a00d0e18cf39dfebb
parent 406042a5
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment