提交 0ddc24d2 编写于 作者: P Paul B Mahol

avfilter/af_dynaudnorm: fix hang with too short input

The only thing we can do at such point is return samples unchanged.
Signed-off-by: NPaul B Mahol <onemda@gmail.com>
上级 762bf6f4
......@@ -708,8 +708,15 @@ static int request_frame(AVFilterLink *outlink)
ret = ff_request_frame(ctx->inputs[0]);
if (ret == AVERROR_EOF && !ctx->is_disabled && s->delay)
ret = flush_buffer(s, ctx->inputs[0], outlink);
if (ret == AVERROR_EOF && !ctx->is_disabled && s->delay) {
if (!cqueue_empty(s->gain_history_smoothed[0])) {
ret = flush_buffer(s, ctx->inputs[0], outlink);
} else if (s->queue.available) {
AVFrame *out = ff_bufqueue_get(&s->queue);
ret = ff_filter_frame(outlink, out);
}
}
return ret;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册