diff options
author | Dan Albert <danalbert@google.com> | 2015-05-08 10:43:54 -0700 |
---|---|---|
committer | Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de> | 2015-10-19 02:52:34 +0200 |
commit | cb60edaf4944f25f36e6e790682b200bc981d3b2 (patch) | |
tree | 7aba7157d67e36976463a0376d876af062c5f835 | |
parent | 72ae58fdd991f50c084e615776cb5306825f7b19 (diff) | |
download | frameworks_av-cb60edaf4944f25f36e6e790682b200bc981d3b2.zip frameworks_av-cb60edaf4944f25f36e6e790682b200bc981d3b2.tar.gz frameworks_av-cb60edaf4944f25f36e6e790682b200bc981d3b2.tar.bz2 |
Fix comparison sign warnings.
Bug:23213430
Change-Id: I6f2e2b03b968a569b122004b4803c5d17fccfb12
(cherry picked from commit 635bc8f90429b2fdcaf7f8d43f7f59bcd0fe951c)
Tested-by: Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de>
-rw-r--r-- | media/libstagefright/MPEG4Extractor.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/media/libstagefright/MPEG4Extractor.cpp b/media/libstagefright/MPEG4Extractor.cpp index 16ff80b..008c410 100644 --- a/media/libstagefright/MPEG4Extractor.cpp +++ b/media/libstagefright/MPEG4Extractor.cpp @@ -1538,7 +1538,7 @@ status_t MPEG4Extractor::parseChunk(off64_t *offset, int depth) { ALOGV("chunk_data_size = %lld and data_offset = %lld", (long long)chunk_data_size, (long long)data_offset); - if (chunk_data_size >= SIZE_MAX - 1) { + if (chunk_data_size < 0 || static_cast<uint64_t>(chunk_data_size) >= SIZE_MAX - 1) { return ERROR_MALFORMED; } uint8_t *buffer = new uint8_t[chunk_data_size + 1]; |