From: Tim-Philipp Müller Date: Fri, 13 Feb 2015 16:03:53 +0000 (+0000) Subject: videoaggregator: use new gst_aggregator_pad_drop_buffer() X-Git-Tag: 1.19.3~511^2~1294^2~251 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8b87f3f2fe26f2d6fe573f01c0821070f8be570c;p=platform%2Fupstream%2Fgstreamer.git videoaggregator: use new gst_aggregator_pad_drop_buffer() --- diff --git a/gst-libs/gst/video/gstvideoaggregator.c b/gst-libs/gst/video/gstvideoaggregator.c index d9235c3..71458ed 100644 --- a/gst-libs/gst/video/gstvideoaggregator.c +++ b/gst-libs/gst/video/gstvideoaggregator.c @@ -993,8 +993,7 @@ gst_videoaggregator_fill_queues (GstVideoAggregator * vagg, || (pad->buffer && start_time < GST_BUFFER_TIMESTAMP (pad->buffer))) { GST_DEBUG_OBJECT (pad, "Buffer from the past, dropping"); gst_buffer_unref (buf); - buf = gst_aggregator_pad_steal_buffer (bpad); - gst_buffer_unref (buf); + gst_aggregator_pad_drop_buffer (bpad); need_more_data = TRUE; continue; } @@ -1016,8 +1015,7 @@ gst_videoaggregator_fill_queues (GstVideoAggregator * vagg, "output_start_time. Discarding old buffer"); gst_buffer_replace (&pad->buffer, buf); gst_buffer_unref (buf); - buf = gst_aggregator_pad_steal_buffer (bpad); - gst_buffer_unref (buf); + gst_aggregator_pad_drop_buffer (bpad); need_more_data = TRUE; continue; } @@ -1044,8 +1042,7 @@ gst_videoaggregator_fill_queues (GstVideoAggregator * vagg, GST_TIME_ARGS (end_time)); gst_buffer_unref (buf); - buf = gst_aggregator_pad_steal_buffer (bpad); - gst_buffer_unref (buf); + gst_aggregator_pad_drop_buffer (bpad); need_more_data = TRUE; continue; @@ -1076,8 +1073,7 @@ gst_videoaggregator_fill_queues (GstVideoAggregator * vagg, if (pad->priv->end_time != -1 && pad->priv->end_time > end_time) { GST_DEBUG_OBJECT (pad, "Buffer from the past, dropping"); gst_buffer_unref (buf); - buf = gst_aggregator_pad_steal_buffer (bpad); - gst_buffer_unref (buf); + gst_aggregator_pad_drop_buffer (bpad); continue; } @@ -1091,9 +1087,7 @@ gst_videoaggregator_fill_queues (GstVideoAggregator * vagg, pad->priv->end_time = end_time; gst_buffer_unref (buf); - buf = gst_aggregator_pad_steal_buffer (bpad); - if (buf) - gst_buffer_unref (buf); + gst_aggregator_pad_drop_buffer (bpad); eos = FALSE; } else if (start_time >= output_end_time) { GST_DEBUG_OBJECT (pad, "Keeping buffer until %" GST_TIME_FORMAT, @@ -1110,9 +1104,7 @@ gst_videoaggregator_fill_queues (GstVideoAggregator * vagg, " out end %" GST_TIME_FORMAT, GST_TIME_ARGS (start_time), GST_TIME_ARGS (output_end_time)); gst_buffer_unref (buf); - buf = gst_aggregator_pad_steal_buffer (bpad); - if (buf) - gst_buffer_unref (buf); + gst_aggregator_pad_drop_buffer (bpad); need_more_data = TRUE; continue;