Skip to content
This repository has been archived by the owner on Nov 15, 2022. It is now read-only.

Commit

Permalink
Handle anonymous sender
Browse files Browse the repository at this point in the history
In some places (such as Korea), it's possible to receive
a message without the sender's address. In this case,
all such anonymous messages will get added to the same
thread. Bug 2665039

Change-Id: Ic6bf7a7bfadfd3162d21ef4a59788b8886679872
  • Loading branch information
Tom Taylor committed May 7, 2010
1 parent a8c49a4 commit b142ea0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/com/android/mms/data/Contact.java
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,10 @@ public Contact get(String number, boolean canBlock) {
if (V) logWithTrace("get(%s, %s)", number, canBlock);

if (TextUtils.isEmpty(number)) {
throw new IllegalArgumentException("Contact.get called with null or empty number");
number = ""; // In some places (such as Korea), it's possible to receive
// a message without the sender's address. In this case,
// all such anonymous messages will get added to the same
// thread.
}

// Always return a Contact object, if if we don't have an actual contact
Expand Down

0 comments on commit b142ea0

Please sign in to comment.