mirror of
https://gitee.com/openharmony/third_party_ffmpeg
synced 2024-11-23 11:19:55 +00:00
vc1: check image height, fix division by 0
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
8824a9ed22
commit
b5f4836f8c
@ -5521,6 +5521,11 @@ static int vc1_decode_frame(AVCodecContext *avctx, void *data,
|
||||
goto err;
|
||||
}
|
||||
|
||||
if ((s->mb_height >> v->field_mode) == 0) {
|
||||
av_log(v->s.avctx, AV_LOG_ERROR, "image too short\n");
|
||||
goto err;
|
||||
}
|
||||
|
||||
// process pulldown flags
|
||||
s->current_picture_ptr->f.repeat_pict = 0;
|
||||
// Pulldown flags are only valid when 'broadcast' has been set.
|
||||
|
Loading…
Reference in New Issue
Block a user