From ba114b6b2221bb9513907c51347ef06e5a26327c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Thu, 27 Mar 2014 19:42:52 +0100 Subject: [PATCH] tsdemux: Ensure that all pending data is pushed even if the stream was not activated before gst_ts_demux_push_pending_data() will check if it now can activate the stream and add the pad, we don't have to check that ourselves. Fixes playback of very short MPEG TS files. --- gst/mpegtsdemux/tsdemux.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gst/mpegtsdemux/tsdemux.c b/gst/mpegtsdemux/tsdemux.c index ed78fd1e4a..b2ab60f3c8 100644 --- a/gst/mpegtsdemux/tsdemux.c +++ b/gst/mpegtsdemux/tsdemux.c @@ -669,7 +669,7 @@ push_event (MpegTSBase * base, GstEvent * event) TSDemuxStream *stream = (TSDemuxStream *) tmp->data; if (stream->pad) { /* If we are pushing out EOS, flush out pending data first */ - if (GST_EVENT_TYPE (event) == GST_EVENT_EOS && stream->active && + if (GST_EVENT_TYPE (event) == GST_EVENT_EOS && gst_pad_is_active (stream->pad)) gst_ts_demux_push_pending_data (demux, stream);