Add check for null contact name when setting up dictionary.

Bug 2021966
main
Eric Fischer 2009-07-29 17:02:20 -07:00 committed by Jean-Baptiste Queru
parent 2bed1531c2
commit e5c7f0981d
1 changed files with 20 additions and 17 deletions

View File

@ -90,6 +90,8 @@ public class ContactsDictionary extends ExpandableDictionary {
if (cursor.moveToFirst()) { if (cursor.moveToFirst()) {
while (!cursor.isAfterLast()) { while (!cursor.isAfterLast()) {
String name = cursor.getString(INDEX_NAME); String name = cursor.getString(INDEX_NAME);
if (name != null) {
int len = name.length(); int len = name.length();
// TODO: Better tokenization for non-Latin writing systems // TODO: Better tokenization for non-Latin writing systems
@ -115,6 +117,7 @@ public class ContactsDictionary extends ExpandableDictionary {
} }
} }
} }
}
cursor.moveToNext(); cursor.moveToNext();
} }