From b0298ad4e5448d949c6e4a3cdd55de223cb59865 Mon Sep 17 00:00:00 2001 From: Paul B Mahol Date: Wed, 2 Dec 2020 12:38:29 +0100 Subject: [PATCH] avfilter/af_acrossover: remove pointless allocation of static size --- libavfilter/af_acrossover.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/libavfilter/af_acrossover.c b/libavfilter/af_acrossover.c index 241f1dbb77..60bb2330f0 100644 --- a/libavfilter/af_acrossover.c +++ b/libavfilter/af_acrossover.c @@ -62,7 +62,7 @@ typedef struct AudioCrossoverContext { int first_order; int ap_filter_count; int nb_splits; - float *splits; + float splits[MAX_SPLITS]; BiquadCoeffs lp[MAX_BANDS][20]; BiquadCoeffs hp[MAX_BANDS][20]; @@ -110,10 +110,6 @@ static av_cold int init(AVFilterContext *ctx) if (!s->fdsp) return AVERROR(ENOMEM); - s->splits = av_calloc(MAX_SPLITS, sizeof(*s->splits)); - if (!s->splits) - return AVERROR(ENOMEM); - p = s->splits_str; for (i = 0; i < MAX_SPLITS; i++) { float freq; @@ -513,7 +509,6 @@ static av_cold void uninit(AVFilterContext *ctx) int i; av_freep(&s->fdsp); - av_freep(&s->splits); av_frame_free(&s->xover); for (i = 0; i < ctx->nb_outputs; i++)