avcodec/smvjpegdec: Dont ignore avcodec_close() return code

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2014-05-20 02:21:07 +02:00
parent 0739614c9c
commit 8408720453

View File

@ -180,13 +180,14 @@ static av_cold int smvjpeg_decode_end(AVCodecContext *avctx)
{
SMVJpegDecodeContext *s = avctx->priv_data;
MJpegDecodeContext *jpg = &s->jpg;
int ret;
jpg->picture_ptr = NULL;
av_frame_free(&s->picture[0]);
av_frame_free(&s->picture[1]);
avcodec_close(s->avctx);
ret = avcodec_close(s->avctx);
av_freep(&s->avctx);
return 0;
return ret;
}
static const AVClass smvjpegdec_class = {