| Index: patched-ffmpeg-mt/libavcodec/h264_ps.c
|
| ===================================================================
|
| --- patched-ffmpeg-mt/libavcodec/h264_ps.c (revision 41250)
|
| +++ patched-ffmpeg-mt/libavcodec/h264_ps.c (working copy)
|
| @@ -176,7 +176,7 @@
|
| if(sps->timing_info_present_flag){
|
| sps->num_units_in_tick = get_bits_long(&s->gb, 32);
|
| sps->time_scale = get_bits_long(&s->gb, 32);
|
| - if(sps->num_units_in_tick-1 > 0x7FFFFFFEU || sps->time_scale-1 > 0x7FFFFFFEU){
|
| + if(!sps->num_units_in_tick || !sps->time_scale){
|
| av_log(h->s.avctx, AV_LOG_ERROR, "time_scale/num_units_in_tick invalid or unsupported (%d/%d)\n", sps->time_scale, sps->num_units_in_tick);
|
| return -1;
|
| }
|
| @@ -347,6 +347,10 @@
|
| sps->mb_aff= 0;
|
|
|
| sps->direct_8x8_inference_flag= get_bits1(&s->gb);
|
| + if(!sps->frame_mbs_only_flag && !sps->direct_8x8_inference_flag){
|
| + av_log(h->s.avctx, AV_LOG_ERROR, "This stream was generated by a broken encoder, invalid 8x8 inference\n");
|
| + goto fail;
|
| + }
|
|
|
| #ifndef ALLOW_INTERLACE
|
| if(sps->mb_aff)
|
|
|