Commit 606c5c7f authored by Jacob Trimble's avatar Jacob Trimble Committed by Michael Niedermayer

avformat/mov: Fix memory leak in encryption info.

Signed-off-by: 's avatarJacob Trimble <modmaker@google.com>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent fbfee6ad
......@@ -5833,6 +5833,7 @@ static int mov_read_sample_encryption_info(MOVContext *c, AVIOContext *pb, MOVSt
if (use_subsamples) {
subsample_count = avio_rb16(pb);
av_free((*sample)->subsamples);
(*sample)->subsamples = av_mallocz_array(subsample_count, sizeof(*subsamples));
if (!(*sample)->subsamples) {
av_encryption_info_free(*sample);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment