diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-03-10 11:48:43 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-04-03 16:40:13 +0200 |
commit | 7f125c3e87f0ce48abfdbcf02e3d4c1c33f025ba (patch) | |
tree | 567bf6993ee915368b0c331ba85d067aea43ddb7 | |
parent | 2ee453610fafb83f1442d764c75554d83508cdb5 (diff) | |
download | ffmpeg-7f125c3e87f0ce48abfdbcf02e3d4c1c33f025ba.tar.gz |
Move frame_pred_frame_dct check elsewhere.
Fixes issue2405
-rw-r--r-- | libavcodec/mpeg12.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/libavcodec/mpeg12.c b/libavcodec/mpeg12.c index e2633c9eaa..dde851002b 100644 --- a/libavcodec/mpeg12.c +++ b/libavcodec/mpeg12.c @@ -406,6 +406,10 @@ static int mpeg_decode_mb(MpegEncContext *s, } break; case MT_FIELD: + if(s->progressive_sequence){ + av_log(s->avctx, AV_LOG_ERROR, "MT_FIELD in progressive_sequence\n"); + return -1; + } s->mv_type = MV_TYPE_FIELD; if (s->picture_structure == PICT_FRAME) { mb_type |= MB_TYPE_16x8 | MB_TYPE_INTERLACED; @@ -443,6 +447,10 @@ static int mpeg_decode_mb(MpegEncContext *s, } break; case MT_DMV: + if(s->progressive_sequence){ + av_log(s->avctx, AV_LOG_ERROR, "MT_DMV in progressive_sequence\n"); + return -1; + } s->mv_type = MV_TYPE_DMV; for(i=0;i<2;i++) { if (USES_LIST(mb_type, i)) { @@ -1587,7 +1595,6 @@ static void mpeg_decode_picture_coding_extension(Mpeg1Context *s1) if(s->progressive_sequence && !s->frame_pred_frame_dct){ av_log(s->avctx, AV_LOG_ERROR, "invalid frame_pred_frame_dct\n"); - s->frame_pred_frame_dct= 1; } if(s->picture_structure == PICT_FRAME){ |