summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNick Kralevich <nnk@google.com>2015-04-11 00:45:25 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2015-04-11 00:45:25 +0000
commit0dc95be53182d7248d0af32f3025097171100204 (patch)
treed2a8822fc697398b0cd5b63097b2aa90a82cf253
parentef6a1a212ff0e9f52db7dcc55117a0df9efa15b3 (diff)
parent17b6f9b0b5c53a46dc1a04162f32d5785e01e58d (diff)
downloadframeworks_av-0dc95be53182d7248d0af32f3025097171100204.zip
frameworks_av-0dc95be53182d7248d0af32f3025097171100204.tar.gz
frameworks_av-0dc95be53182d7248d0af32f3025097171100204.tar.bz2
am 17b6f9b0: am 3b042ea5: am 7d62a918: am 14c686c0: am 940189d9: am 475de998: am 47759307: am 17b625b7: Merge "Fix integer overflow during MP4 atom processing" into klp-dev
* commit '17b6f9b0b5c53a46dc1a04162f32d5785e01e58d': Fix integer overflow during MP4 atom processing
-rw-r--r--media/libstagefright/SampleTable.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/media/libstagefright/SampleTable.cpp b/media/libstagefright/SampleTable.cpp
index b572af3..6030236 100644
--- a/media/libstagefright/SampleTable.cpp
+++ b/media/libstagefright/SampleTable.cpp
@@ -230,6 +230,9 @@ status_t SampleTable::setSampleToChunkParams(
return ERROR_MALFORMED;
}
+ if (SIZE_MAX / sizeof(SampleToChunkEntry) <= mNumSampleToChunkOffsets)
+ return ERROR_OUT_OF_RANGE;
+
mSampleToChunkEntries =
new SampleToChunkEntry[mNumSampleToChunkOffsets];