Add protective code for http://b/issue?id=2135578
-I couldn't repro this bug, so I just added protection against it.
Change-Id: I350602b403c39c407c3c54f39a2d44dc3e5ec317
diff --git a/src/com/android/contacts/ContactsListActivity.java b/src/com/android/contacts/ContactsListActivity.java
index 5d47ee4..c897317 100644
--- a/src/com/android/contacts/ContactsListActivity.java
+++ b/src/com/android/contacts/ContactsListActivity.java
@@ -2017,7 +2017,15 @@
switch(message.what) {
case FETCH_IMAGE_MSG: {
final ImageView imageView = (ImageView) message.obj;
+ if (imageView == null) {
+ break;
+ }
+
final PhotoInfo info = (PhotoInfo)imageView.getTag();
+ if (info == null) {
+ break;
+ }
+
final long photoId = info.photoId;
if (photoId == 0) {
break;
@@ -2029,7 +2037,6 @@
} catch (OutOfMemoryError e) {
// Not enough memory for the photo, do nothing.
}
-
if (photo == null) {
break;
}