Commit 4ffec6d9 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/twinvq: Use av_freep() to avoid leaving stale pointers in memory

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent b9792afa
...@@ -755,13 +755,13 @@ av_cold int ff_twinvq_decode_close(AVCodecContext *avctx) ...@@ -755,13 +755,13 @@ av_cold int ff_twinvq_decode_close(AVCodecContext *avctx)
for (i = 0; i < 3; i++) { for (i = 0; i < 3; i++) {
ff_mdct_end(&tctx->mdct_ctx[i]); ff_mdct_end(&tctx->mdct_ctx[i]);
av_free(tctx->cos_tabs[i]); av_freep(&tctx->cos_tabs[i]);
} }
av_free(tctx->curr_frame); av_freep(&tctx->curr_frame);
av_free(tctx->spectrum); av_freep(&tctx->spectrum);
av_free(tctx->prev_frame); av_freep(&tctx->prev_frame);
av_free(tctx->tmp_buf); av_freep(&tctx->tmp_buf);
return 0; return 0;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment