diff --git a/libavcodec/h261dec.c b/libavcodec/h261dec.c index cabca33c8d..50ac53167d 100644 --- a/libavcodec/h261dec.c +++ b/libavcodec/h261dec.c @@ -587,8 +587,7 @@ static int h261_decode_frame(AVCodecContext *avctx, AVFrame *pict, return ret; } - if ((avctx->skip_frame >= AVDISCARD_NONREF && s->pict_type == AV_PICTURE_TYPE_B) || - (avctx->skip_frame >= AVDISCARD_NONKEY && s->pict_type != AV_PICTURE_TYPE_I) || + if ((avctx->skip_frame >= AVDISCARD_NONKEY && s->pict_type != AV_PICTURE_TYPE_I) || avctx->skip_frame >= AVDISCARD_ALL) return buf_size;