avsdec: Set dimensions instead of relying on the demuxer.

This fixes out of array writes.

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
pull/5/head
Michael Niedermayer 13 years ago
parent 34c426be4a
commit 1df49142ba
  1. 1
      libavcodec/avs.c

@ -162,6 +162,7 @@ static av_cold int avs_decode_init(AVCodecContext * avctx)
AvsContext *const avs = avctx->priv_data;
avctx->pix_fmt = PIX_FMT_PAL8;
avcodec_get_frame_defaults(&avs->picture);
avcodec_set_dimensions(avctx, 318, 198);
return 0;
}

Loading…
Cancel
Save