avformat/mov: Check avif_info

Fixes: leak
Fixes: 45982/clusterfuzz-testcase-minimized-ffmpeg_DEMUXER_fuzzer-6674082962997248
Fixes: 62164/clusterfuzz-testcase-minimized-ffmpeg_DEMUXER_fuzzer-6674082962997248

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
pull/390/head
Michael Niedermayer 1 year ago
parent f904e60c32
commit 9a3bbf89bd
No known key found for this signature in database
GPG Key ID: B18E8928B3948D64
  1. 3
      libavformat/mov.c

@ -7772,10 +7772,11 @@ static int mov_read_iloc(MOVContext *c, AVIOContext *pb, MOVAtom atom)
return 0;
}
if (c->fc->nb_streams) {
if (c->avif_info) {
av_log(c->fc, AV_LOG_INFO, "Duplicate iloc box found\n");
return 0;
}
av_assert0(!c->fc->nb_streams);
version = avio_r8(pb);
avio_rb24(pb); // flags.

Loading…
Cancel
Save