Make vCard composer handle null of Photo entry correctly.
Internal bug id: 2088922
diff --git a/core/java/android/pim/vcard/VCardComposer.java b/core/java/android/pim/vcard/VCardComposer.java
index 283d00b..5a09c64f 100644
--- a/core/java/android/pim/vcard/VCardComposer.java
+++ b/core/java/android/pim/vcard/VCardComposer.java
@@ -967,6 +967,9 @@
if (contentValuesList != null) {
for (ContentValues contentValues : contentValuesList) {
byte[] data = contentValues.getAsByteArray(Photo.PHOTO);
+ if (data == null) {
+ continue;
+ }
final String photoType;
// Use some heuristics for guessing the format of the image.
// TODO: there should be some general API for detecting the file format.