Fix NPE in MissedCallNotifierImpl
Check to see if the caller info is null before trying to access its
contact display photo URI
Change-Id: I9461797074a6815b662bd7796fc3a4a6cbc558da
Fix: 34396500
Test: manual
diff --git a/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java b/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java
index 3b8e7e0..863c393 100644
--- a/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java
+++ b/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java
@@ -625,8 +625,10 @@
"different handle.");
return;
}
- if (info.contactDisplayPhotoUri == null) {
- // If there is no photo, just show the notification.
+ if (info == null ||
+ info.contactDisplayPhotoUri == null) {
+ // If there is no photo or if the caller info is
+ // null, just show the notification.
CallInfo callInfo = callInfoFactory.makeCallInfo(
info, null, handle, date);
showMissedCallNotification(callInfo, userHandle);