ffmpeg | branch: release/7.1 | Michael Niedermayer <mich...@niedermayer.cc> | Tue Jan 7 23:21:32 2025 +0100| [0bb8a38c10a16c6956baabbf0dd9a2f634c89a01] | committer: Michael Niedermayer
avformat/mov: perform sanity checks for heif before index building Fixes: undefined NULL pointer use Fixes: clusterfuzz-testcase-minimized-audio_decoder_fuzzer-6363211175493632 This performs equivalent sanity checks as are done in mov_read_trak() before mov_build_index() Reported-by: Dale Curtis <dalecur...@chromium.org> Signed-off-by: Michael Niedermayer <mich...@niedermayer.cc> (cherry picked from commit afbc3a1b23b3ba3e5a3f2820228a5fe51b517be7) Signed-off-by: Michael Niedermayer <mich...@niedermayer.cc> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0bb8a38c10a16c6956baabbf0dd9a2f634c89a01 --- libavformat/mov.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavformat/mov.c b/libavformat/mov.c index 6918a6e045..695b975147 100644 --- a/libavformat/mov.c +++ b/libavformat/mov.c @@ -10136,7 +10136,8 @@ static int mov_parse_heif_items(AVFormatContext *s) st->codecpar->width = item->width; st->codecpar->height = item->height; - if (sc->sample_count != 1 || sc->chunk_count != 1) + err = sanity_checks(s, sc, item->item_id); + if (err) return AVERROR_INVALIDDATA; sc->sample_sizes[0] = item->extent_length; _______________________________________________ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".