aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorandroid-build-team Robot <android-build-team-robot@google.com>2019-06-11 21:07:37 +0000
committerandroid-build-team Robot <android-build-team-robot@google.com>2019-06-11 21:07:37 +0000
commitb17ee7f84385758941d5fe278dcf9dc902b3e2bb (patch)
tree527dca25ecc3b0662761b1c5858880ad907558ea
parent3b55f75a09b097c6877b47d6e9edba9563eff27f (diff)
parent3dc46e71643c37d38a725303bd14a2c2a36338f3 (diff)
downloadlibvpx-pie-qpr3-release.tar.gz
Merge cherrypicks of [7982564, 7982192, 7982565, 7981411, 7982522, 7982682, 7982193, 7982194, 7982523, 7982480, 7982623, 7981412, 7981413, 7982605, 7982606, 7982607, 7982608, 7981749, 7981750, 7981751, 7981752, 7981753, 7981754, 7982624, 7982394, 7982395, 7982625, 7982687, 7982566, 7982567, 7982568, 7982688, 7982689, 7982690, 7982195, 7982196, 7982611, 7982612, 7982396, 7982694, 7982695, 7982215] into pi-qpr3-releaseandroid-9.0.0_r46pie-qpr3-release
Change-Id: I6df82ca83364f275ebbf3877d6c1b7eab12c77f0
-rw-r--r--libwebm/mkvparser/mkvparser.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/libwebm/mkvparser/mkvparser.cc b/libwebm/mkvparser/mkvparser.cc
index 70c1f043f..efd35452a 100644
--- a/libwebm/mkvparser/mkvparser.cc
+++ b/libwebm/mkvparser/mkvparser.cc
@@ -4233,6 +4233,7 @@ long ContentEncoding::ParseContentEncodingEntry(long long start, long long size,
new (std::nothrow) ContentEncryption*[encryption_count];
if (!encryption_entries_) {
delete[] compression_entries_;
+ compression_entries_ = NULL;
return -1;
}
encryption_entries_end_ = encryption_entries_;
@@ -4328,6 +4329,12 @@ long ContentEncoding::ParseCompressionEntry(long long start, long long size,
return status;
}
+ // There should be only one settings element per content compression.
+ if (compression->settings != NULL) {
+ delete[] buf;
+ return E_FILE_FORMAT_INVALID;
+ }
+
compression->settings = buf;
compression->settings_len = buflen;
}