Merge "CryptoSession: handle 0-length buffer in DecryptSample" into rvc-dev am: e59339ed6d am: 94108cdbe8 am: 08eb9a7fae am: 29b6a916c9

Change-Id: I912abc7d15b847fc116d15b9ff919db557a4d7c0
This commit is contained in:
TreeHugger Robot
2020-04-01 06:15:15 +00:00
committed by Automerger Merge Worker

View File

@@ -2693,6 +2693,7 @@ OEMCryptoResult CryptoSession::DecryptSample(
if (sts == OEMCrypto_ERROR_BUFFER_TOO_LARGE) {
// Fall back to sending each subsample region individually
sts = OEMCrypto_SUCCESS;
OEMCrypto_SampleDescription fake_sample = sample;
for (size_t i = 0; i < sample.subsamples_length; ++i) {
const OEMCrypto_SubSampleDescription& original_subsample =