avfilter/af_compand: change error condition into warning

This commit is contained in:
Paul B Mahol 2019-08-06 13:37:58 +02:00
parent f8ad2ddd7a
commit 1232e67b16

View File

@ -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);