diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-07-26 17:45:44 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-07-26 17:45:44 +0200 |
commit | e15e5328a7ad008d111e64d49708894ec6280eed (patch) | |
tree | a63865860519eadf5ba3070334c7dd4e2475fc27 /libavcodec/mpc8.c | |
parent | 5938b4d3983ca39bc37cf70d5920c2ca29ea51cd (diff) | |
download | ffmpeg-e15e5328a7ad008d111e64d49708894ec6280eed.tar.gz |
mpc8: Initialize AVFrame properly
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/mpc8.c')
-rw-r--r-- | libavcodec/mpc8.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libavcodec/mpc8.c b/libavcodec/mpc8.c index 3b98b5f709..d9594ec900 100644 --- a/libavcodec/mpc8.c +++ b/libavcodec/mpc8.c @@ -143,6 +143,9 @@ static av_cold int mpc8_decode_init(AVCodecContext * avctx) avctx->channel_layout = (channels==2) ? AV_CH_LAYOUT_STEREO : AV_CH_LAYOUT_MONO; avctx->channels = channels; + avcodec_get_frame_defaults(&c->frame); + avctx->coded_frame = &c->frame; + if(vlc_initialized) return 0; av_log(avctx, AV_LOG_DEBUG, "Initing VLC\n"); @@ -234,9 +237,6 @@ static av_cold int mpc8_decode_init(AVCodecContext * avctx) } vlc_initialized = 1; - avcodec_get_frame_defaults(&c->frame); - avctx->coded_frame = &c->frame; - return 0; } |