summaryrefslogtreecommitdiff
path: root/libavfilter/audio.c
diff options
context:
space:
mode:
authorNicolas George <nicolas.george@normalesup.org>2012-08-19 19:26:58 +0200
committerNicolas George <nicolas.george@normalesup.org>2012-08-22 19:04:30 +0200
commitbeeba9161a091d4d352e6fe5224c86c383f1aaa7 (patch)
tree66d196392f6052e5ee633f93d721fcb3e289ef77 /libavfilter/audio.c
parentac07f941ae1626bfd8e201a3771c67e54073e31e (diff)
lavfi: add a closed field to AVFilerLink.
It will help forward errors and maintain consistency.
Diffstat (limited to 'libavfilter/audio.c')
-rw-r--r--libavfilter/audio.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libavfilter/audio.c b/libavfilter/audio.c
index 525b471065..e7306b134b 100644
--- a/libavfilter/audio.c
+++ b/libavfilter/audio.c
@@ -172,6 +172,11 @@ int ff_filter_samples_framed(AVFilterLink *link, AVFilterBufferRef *samplesref)
FF_TPRINTF_START(NULL, filter_samples); ff_tlog_link(NULL, link, 1);
+ if (link->closed) {
+ avfilter_unref_buffer(samplesref);
+ return AVERROR_EOF;
+ }
+
if (!(filter_samples = dst->filter_samples))
filter_samples = default_filter_samples;