提交 dd872004 编写于 作者: M Michael Niedermayer

avcodec/wcmv: check remaining space vs. blocks

Fixes: Timeout (18sec  -> 7sec)
Fixes: 14835/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_WCMV_fuzzer-5646714897170432

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpegSigned-off-by: NMichael Niedermayer <michael@niedermayer.cc>
上级 d5a6b390
......@@ -154,6 +154,9 @@ static int decode_frame(AVCodecContext *avctx,
bytestream2_seek(&gb, 2, SEEK_SET);
}
if (bytestream2_get_bytes_left(&gb) < 8LL * blocks)
return AVERROR_INVALIDDATA;
if (s->prev_frame->data[0]) {
ret = av_frame_copy(frame, s->prev_frame);
if (ret < 0)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册