Browse Source

ituh263: reject b-frame with pp_time = 0

Avoid a division by 0 in ff_mpeg4_set_one_direct_mv.

Sample-Id: 00000168-google
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind

Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
tags/n2.3
Keiji Costantini Vittorio Giovara 11 years ago
parent
commit
9514440337
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      libavcodec/ituh263dec.c

+ 2
- 0
libavcodec/ituh263dec.c View File

@@ -750,6 +750,8 @@ int ff_h263_decode_mb(MpegEncContext *s,
}

if(IS_DIRECT(mb_type)){
if (!s->pp_time)
return AVERROR_INVALIDDATA;
s->mv_dir = MV_DIR_FORWARD | MV_DIR_BACKWARD | MV_DIRECT;
mb_type |= ff_mpeg4_set_direct_mv(s, 0, 0);
}else{


Loading…
Cancel
Save