diff options
author | Yin Liu <yin2.liu@sonymobile.com> | 2012-12-04 09:19:53 +0100 |
---|---|---|
committer | Zoran Jovanovic <zoran.jovanovic@sonymobile.com> | 2013-12-20 20:56:12 +0100 |
commit | 014897f5aece2c6212418934bd4618326979f17a (patch) | |
tree | 7875866e28fecefccf204bfcfe157e4ed0e74552 /media/mtp/MtpStringBuffer.h | |
parent | 1f95555c69219180f792ac742cc0e386496c29e6 (diff) | |
download | frameworks_av-014897f5aece2c6212418934bd4618326979f17a.zip frameworks_av-014897f5aece2c6212418934bd4618326979f17a.tar.gz frameworks_av-014897f5aece2c6212418934bd4618326979f17a.tar.bz2 |
Long mp3 metadata displays as corrupted file after transfer
Cut the metadata to 1 Byte and return in function
getObjectPropertyList in order to show it properly on a PC.
Change-Id: Iefacf9fa86c20ece2572e6d95d35877a94066fe7
Diffstat (limited to 'media/mtp/MtpStringBuffer.h')
-rw-r--r-- | media/mtp/MtpStringBuffer.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/media/mtp/MtpStringBuffer.h b/media/mtp/MtpStringBuffer.h index cbc8307..e5150df 100644 --- a/media/mtp/MtpStringBuffer.h +++ b/media/mtp/MtpStringBuffer.h @@ -19,6 +19,9 @@ #include <stdint.h> +// Max Character number of a MTP String +#define MTP_STRING_MAX_CHARACTER_NUMBER 255 + namespace android { class MtpDataPacket; @@ -29,7 +32,7 @@ class MtpStringBuffer { private: // mBuffer contains string in UTF8 format // maximum 3 bytes/character, with 1 extra for zero termination - uint8_t mBuffer[255 * 3 + 1]; + uint8_t mBuffer[MTP_STRING_MAX_CHARACTER_NUMBER * 3 + 1]; int mCharCount; int mByteCount; |