From 1ab33d78feb5d27adf229688ea56b92ce4c40222 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Olivier=20Cr=C3=AAte?= Date: Tue, 9 May 2017 20:20:07 -0400 Subject: [PATCH] aggregator: Set initial position on first buffer Set the initial position on the first buffer, otherwise the queue will grow without limits before the output thread is started. https://bugzilla.gnome.org/show_bug.cgi?id=781673 --- gst-libs/gst/base/gstaggregator.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gst-libs/gst/base/gstaggregator.c b/gst-libs/gst/base/gstaggregator.c index 14bef99..cd146fd 100644 --- a/gst-libs/gst/base/gstaggregator.c +++ b/gst-libs/gst/base/gstaggregator.c @@ -1026,6 +1026,9 @@ update_time_level (GstAggregatorPad * aggpad, gboolean head) GST_FORMAT_TIME, aggpad->priv->head_position); else aggpad->priv->head_time = GST_CLOCK_TIME_NONE; + + if (!GST_CLOCK_TIME_IS_VALID (aggpad->priv->tail_time)) + aggpad->priv->tail_time = aggpad->priv->head_time; } else { if (GST_CLOCK_TIME_IS_VALID (aggpad->priv->tail_position) && aggpad->segment.format == GST_FORMAT_TIME) -- 2.7.4