Mercurial > libavcodec.hg
comparison psymodel.c @ 11995:0d0446295060 libavcodec
Make ff_psy_preprocess_end() act like av_freep().
author | alexc |
---|---|
date | Mon, 28 Jun 2010 21:36:19 +0000 |
parents | 9db3fbaba639 |
children | e0dae84d60ae |
comparison
equal
deleted
inserted
replaced
11994:ea2cb1a9e815 | 11995:0d0446295060 |
---|---|
115 } | 115 } |
116 } | 116 } |
117 | 117 |
118 av_cold void ff_psy_preprocess_end(struct FFPsyPreprocessContext *ctx) | 118 av_cold void ff_psy_preprocess_end(struct FFPsyPreprocessContext *ctx) |
119 { | 119 { |
120 if (ctx) { | |
120 int i; | 121 int i; |
121 ff_iir_filter_free_coeffs(ctx->fcoeffs); | 122 ff_iir_filter_free_coeffs(ctx->fcoeffs); |
122 if (ctx->fstate) | 123 if (ctx->fstate) |
123 for (i = 0; i < ctx->avctx->channels; i++) | 124 for (i = 0; i < ctx->avctx->channels; i++) |
124 ff_iir_filter_free_state(ctx->fstate[i]); | 125 ff_iir_filter_free_state(ctx->fstate[i]); |
125 av_freep(&ctx->fstate); | 126 av_freep(&ctx->fstate); |
127 } | |
128 ctx = NULL; | |
126 } | 129 } |
127 | 130 |