summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
authorMarco Nelissen <marcone@google.com>2015-10-22 19:58:45 +0000
committerAndroid (Google) Code Review <android-gerrit@google.com>2015-10-22 19:58:45 +0000
commit78c164c2386a24c6ea4455883a54acbbc20056e9 (patch)
treeb639c9166e81ddd4955b0b849f80f2303c4fe367 /media
parentc0d8c35a2d3873ef1d7c7e5c5eaa51f41c1c3a17 (diff)
parent8ee368522ca7df126033a05dc3c430182b4495c9 (diff)
downloadframeworks_av-78c164c2386a24c6ea4455883a54acbbc20056e9.zip
frameworks_av-78c164c2386a24c6ea4455883a54acbbc20056e9.tar.gz
frameworks_av-78c164c2386a24c6ea4455883a54acbbc20056e9.tar.bz2
Merge "Fix offset adjustment when skipping off-spec meta chunk" into mnc-dr-dev
Diffstat (limited to 'media')
-rwxr-xr-xmedia/libstagefright/MPEG4Extractor.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/media/libstagefright/MPEG4Extractor.cpp b/media/libstagefright/MPEG4Extractor.cpp
index a1af3aa..bfdff38 100755
--- a/media/libstagefright/MPEG4Extractor.cpp
+++ b/media/libstagefright/MPEG4Extractor.cpp
@@ -1776,13 +1776,13 @@ status_t MPEG4Extractor::parseChunk(off64_t *offset, int depth) {
if (!isParsingMetaKeys) {
uint8_t buffer[4];
if (chunk_data_size < (off64_t)sizeof(buffer)) {
- *offset += chunk_size;
+ *offset = stop_offset;
return ERROR_MALFORMED;
}
if (mDataSource->readAt(
data_offset, buffer, 4) < 4) {
- *offset += chunk_size;
+ *offset = stop_offset;
return ERROR_IO;
}
@@ -1793,7 +1793,7 @@ status_t MPEG4Extractor::parseChunk(off64_t *offset, int depth) {
// apparently malformed chunks that don't have flags
// and completely different semantics than what's
// in the MPEG4 specs and skip it.
- *offset += chunk_size;
+ *offset = stop_offset;
return OK;
}
*offset += sizeof(buffer);