diff options
author | Wei Jia <wjia@google.com> | 2015-10-06 16:38:51 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2015-10-06 16:38:51 +0000 |
commit | df68d9d5bf5329bc2f7effb6afa1d3904eaf30d8 (patch) | |
tree | 351e7418e7b246e6355d733dda07997985862758 | |
parent | 13b6b51e6d9c399f0bfa55be4eecaf47b63845f2 (diff) | |
parent | 60b25aa0c173854593743dd85588c7449baf87c0 (diff) | |
download | frameworks_av-df68d9d5bf5329bc2f7effb6afa1d3904eaf30d8.zip frameworks_av-df68d9d5bf5329bc2f7effb6afa1d3904eaf30d8.tar.gz frameworks_av-df68d9d5bf5329bc2f7effb6afa1d3904eaf30d8.tar.bz2 |
am 60b25aa0: am 9ab9c85e: Merge "MPEG4Extractor: ensure buffer size is not less than 8 for LastCommentData." into klp-dev
* commit '60b25aa0c173854593743dd85588c7449baf87c0':
MPEG4Extractor: ensure buffer size is not less than 8 for LastCommentData.
-rw-r--r-- | media/libstagefright/MPEG4Extractor.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/media/libstagefright/MPEG4Extractor.cpp b/media/libstagefright/MPEG4Extractor.cpp index e09ecc2..d9975bb 100644 --- a/media/libstagefright/MPEG4Extractor.cpp +++ b/media/libstagefright/MPEG4Extractor.cpp @@ -2347,6 +2347,12 @@ status_t MPEG4Extractor::parseITunesMetaData(off64_t offset, size_t size) { mLastCommentName.setTo((const char *)buffer + 4); break; case FOURCC('d', 'a', 't', 'a'): + if (size < 8) { + delete[] buffer; + buffer = NULL; + ALOGE("b/24346430"); + return ERROR_MALFORMED; + } mLastCommentData.setTo((const char *)buffer + 8); break; } |