You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
avformat/mov: Corner case encryption error cleanup in mov_read_senc()
Fixes: memleak Fixes: 42341/clusterfuzz-testcase-minimized-ffmpeg_dem_MOV_fuzzer-4566632823914496 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
@@ -6105,6 +6105,8 @@ static int mov_read_senc(MOVContext *c, AVIOContext *pb, MOVAtom atom)
|
|||||||
}
|
}
|
||||||
if (pb->eof_reached) {
|
if (pb->eof_reached) {
|
||||||
av_log(c->fc, AV_LOG_ERROR, "Hit EOF while reading senc\n");
|
av_log(c->fc, AV_LOG_ERROR, "Hit EOF while reading senc\n");
|
||||||
|
if (ret >= 0)
|
||||||
|
av_encryption_info_free(encryption_index->encrypted_samples[i]);
|
||||||
ret = AVERROR_INVALIDDATA;
|
ret = AVERROR_INVALIDDATA;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user