From 8e4f966018409592eca28014bdafaffb4ef59d0a Mon Sep 17 00:00:00 2001 From: Jesper Larsen Date: Wed, 6 Mar 2013 12:15:47 +0100 Subject: [PATCH] tsdemux: fix program-number functionality Setting the program-number property does not affect which program is actually being demuxed. Moving the initialization of the program_number from gst_ts_demux_reset to gst_ts_demux_init seems to fix this issue. https://bugzilla.gnome.org/show_bug.cgi?id=690934 --- 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 914967cc81..cc09269ff6 100644 --- a/gst/mpegtsdemux/tsdemux.c +++ b/gst/mpegtsdemux/tsdemux.c @@ -317,7 +317,6 @@ gst_ts_demux_reset (MpegTSBase * base) { GstTSDemux *demux = (GstTSDemux *) base; - demux->program_number = -1; demux->calculate_update_segment = FALSE; gst_segment_init (&demux->segment, GST_FORMAT_UNDEFINED); @@ -342,6 +341,7 @@ gst_ts_demux_init (GstTSDemux * demux) /* We are not interested in sections (all handled by mpegtsbase) */ base->push_section = FALSE; + demux->program_number = -1; gst_ts_demux_reset (base); }