From 1232e67b16dd67625f130850a99a4e66d44b5888 Mon Sep 17 00:00:00 2001 From: Paul B Mahol Date: Tue, 6 Aug 2019 13:37:58 +0200 Subject: [PATCH] avfilter/af_compand: change error condition into warning --- libavfilter/af_compand.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/libavfilter/af_compand.c b/libavfilter/af_compand.c index c138f0b1d8..d4a816d135 100644 --- a/libavfilter/af_compand.c +++ b/libavfilter/af_compand.c @@ -349,9 +349,10 @@ static int config_output(AVFilterLink *outlink) } if (nb_attacks > channels || nb_decays > channels) { - av_log(ctx, AV_LOG_ERROR, - "Number of attacks/decays bigger than number of channels.\n"); - return AVERROR(EINVAL); + av_log(ctx, AV_LOG_WARNING, + "Number of attacks/decays bigger than number of channels. Ignoring rest of entries.\n"); + nb_attacks = FFMIN(nb_attacks, channels); + nb_decays = FFMIN(nb_decays, channels); } uninit(ctx);