mpeg4videoenc: check w,h to be within the supported range.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
pull/28/head^2
Michael Niedermayer 12 years ago
parent 46cb61819d
commit 7e059c9c5d
  1. 5
      libavcodec/mpeg4videoenc.c

@ -1234,6 +1234,11 @@ static av_cold int encode_init(AVCodecContext *avctx)
int ret;
static int done = 0;
if (avctx->width >= (1<<13) || avctx->height >= (1<<13)) {
av_log(avctx, AV_LOG_ERROR, "dimensions too large for MPEG-4\n");
return AVERROR(EINVAL);
}
if((ret=ff_MPV_encode_init(avctx)) < 0)
return ret;

Loading…
Cancel
Save