Make vCard composer handle null of Photo entry correctly.

Internal bug id: 2088922
This commit is contained in:
Daisuke Miyakawa
2009-09-01 07:17:20 +09:00
parent ee0e24c105
commit f75c94f7a9

View File

@@ -967,6 +967,9 @@ public class VCardComposer {
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.