aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/qdmc.c
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2018-09-08 15:43:46 +0200
committerPaul B Mahol <onemda@gmail.com>2018-09-08 15:43:46 +0200
commitd8ad8fd8bd25072b383ec4edf9f709ff52a4b9b3 (patch)
treed419580d78975c66a840a39702d815468318f935 /libavcodec/qdmc.c
parentc4cda4eb878affb89c031fa7e0cc3349c9a502cd (diff)
downloadffmpeg-d8ad8fd8bd25072b383ec4edf9f709ff52a4b9b3.tar.gz
avcodec/qdmc: check return code of ff_fft_init()
Diffstat (limited to 'libavcodec/qdmc.c')
-rw-r--r--libavcodec/qdmc.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libavcodec/qdmc.c b/libavcodec/qdmc.c
index f1f86accd8..8f5b7b920d 100644
--- a/libavcodec/qdmc.c
+++ b/libavcodec/qdmc.c
@@ -253,7 +253,7 @@ static av_cold int qdmc_decode_init(AVCodecContext *avctx)
{
static AVOnce init_static_once = AV_ONCE_INIT;
QDMCContext *s = avctx->priv_data;
- int fft_size, fft_order, size, g, j, x;
+ int ret, fft_size, fft_order, size, g, j, x;
GetByteContext b;
ff_thread_once(&init_static_once, qdmc_init_static_data);
@@ -338,7 +338,9 @@ static av_cold int qdmc_decode_init(AVCodecContext *avctx)
return AVERROR_INVALIDDATA;
}
- ff_fft_init(&s->fft_ctx, fft_order, 1);
+ ret = ff_fft_init(&s->fft_ctx, fft_order, 1);
+ if (ret < 0)
+ return ret;
avctx->sample_fmt = AV_SAMPLE_FMT_S16;