diff options
author | Yorke Lee <yorkelee@google.com> | 2015-12-09 11:40:15 -0800 |
---|---|---|
committer | Yorke Lee <yorkelee@google.com> | 2015-12-10 21:17:33 +0000 |
commit | 52cd5fd66d0b97e066f89281eb55016dedfeec3a (patch) | |
tree | 9a0b54aba1be8d33e46b4bf87e8cd4311f02cb37 /src | |
parent | f63db143d4b83021bc0a29dda91536d52756423d (diff) |
Fix potential NPE in DefaultVoicemailNotifier
Don't try to format an empty number
Bug: 26095129
Change-Id: I6356c24e03066babd22217b24004f9ae9a53a67b
Diffstat (limited to 'src')
-rw-r--r-- | src/com/android/dialer/calllog/DefaultVoicemailNotifier.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java b/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java index c40c99384..2b894a12d 100644 --- a/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java +++ b/src/com/android/dialer/calllog/DefaultVoicemailNotifier.java @@ -154,7 +154,7 @@ public class DefaultVoicemailNotifier { if (TextUtils.isEmpty(name)) { // Look it up in the database. name = mNameLookupQuery.query(newCall.number); - if (TextUtils.isEmpty(name)) { + if (TextUtils.isEmpty(name) && !TextUtils.isEmpty(newCall.number)) { name = PhoneNumberUtils.formatNumber(newCall.number, newCall.countryIso); } } |