diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-11-30 14:25:42 +0100 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2021-05-02 03:38:08 +0200 |
commit | 980f002b3f0b63d145918db98cea6bfc5abfc922 (patch) | |
tree | e12c6124b50c51037668dfe1f68d262ed6179614 /libavcodec/cook.c | |
parent | 711f14080c538484432f406917074bda6d6b48ce (diff) | |
download | ffmpeg-980f002b3f0b63d145918db98cea6bfc5abfc922.tar.gz |
avcodec/cook: Remove redundant free
This decoder has the FF_CODEC_CAP_INIT_CLEANUP flag set.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavcodec/cook.c')
-rw-r--r-- | libavcodec/cook.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/libavcodec/cook.c b/libavcodec/cook.c index d1e7e6dd31..0c1d986c45 100644 --- a/libavcodec/cook.c +++ b/libavcodec/cook.c @@ -256,10 +256,9 @@ static av_cold int init_cook_mlt(COOKContext *q) q->mlt_window[j] *= sqrt(2.0 / q->samples_per_channel); /* Initialize the MDCT. */ - if ((ret = ff_mdct_init(&q->mdct_ctx, av_log2(mlt_size) + 1, 1, 1.0 / 32768.0))) { - av_freep(&q->mlt_window); + ret = ff_mdct_init(&q->mdct_ctx, av_log2(mlt_size) + 1, 1, 1.0 / 32768.0); + if (ret < 0) return ret; - } av_log(q->avctx, AV_LOG_DEBUG, "MDCT initialized, order = %d.\n", av_log2(mlt_size) + 1); |