Commit 73c1e3ba authored by Matthieu Bouron's avatar Matthieu Bouron Committed by Michael Niedermayer

asrc_abuffer: return EAGAIN if no frame is available

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 6b55aab0
......@@ -334,11 +334,8 @@ static int request_frame(AVFilterLink *outlink)
ABufferSourceContext *abuffer = outlink->src->priv;
AVFilterBufferRef *samplesref;
if (!av_fifo_size(abuffer->fifo)) {
av_log(outlink->src, AV_LOG_ERROR,
"request_frame() called with no available frames!\n");
return AVERROR(EINVAL);
}
if (!av_fifo_size(abuffer->fifo))
return AVERROR(EAGAIN);
av_fifo_generic_read(abuffer->fifo, &samplesref, sizeof(samplesref), NULL);
avfilter_filter_samples(outlink, avfilter_ref_buffer(samplesref, ~0));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment