From dfd47702bcc634892f4c4f63012010ca0de9568b Mon Sep 17 00:00:00 2001 From: cketti Date: Tue, 14 Feb 2012 00:27:28 +0100 Subject: [PATCH] Fixed rare NullPointerException --- src/com/fsck/k9/EmailAddressAdapter.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com/fsck/k9/EmailAddressAdapter.java b/src/com/fsck/k9/EmailAddressAdapter.java index d9bb59940..8cb0240d9 100644 --- a/src/com/fsck/k9/EmailAddressAdapter.java +++ b/src/com/fsck/k9/EmailAddressAdapter.java @@ -48,7 +48,7 @@ public class EmailAddressAdapter extends ResourceCursorAdapter { final String name = mContacts.getName(cursor); final String address = mContacts.getEmail(cursor); - return new Address(address, name).toString(); + return (address == null) ? "" : new Address(address, name).toString(); } @Override