From c436772120ceea1d6e3f5b388ef068c99c8bb7d6 Mon Sep 17 00:00:00 2001 From: Mike Lockwood Date: Mon, 21 Apr 2014 08:49:30 -0700 Subject: MTP: Fix getThumbnail The thumbnail size was not being passed to the MTP stack so getThumbnail was returning zero length data. Bug: 13747419 Change-Id: I309d35b5c46ab5f631c0dcb5981f7896bb5a2ed5 --- media/jni/android_mtp_MtpDatabase.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'media/jni') diff --git a/media/jni/android_mtp_MtpDatabase.cpp b/media/jni/android_mtp_MtpDatabase.cpp index 067e7a6..f8fb144 100644 --- a/media/jni/android_mtp_MtpDatabase.cpp +++ b/media/jni/android_mtp_MtpDatabase.cpp @@ -849,6 +849,7 @@ void* MyMtpDatabase::getThumbnail(MtpObjectHandle handle, size_t& outThumbSize) result = malloc(exifdata->size); if (result) { memcpy(result, exifdata->data, exifdata->size); + outThumbSize = exifdata->size; } } exif_data_unref(exifdata); -- cgit v1.1