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
This commit is contained in:
Jesper Larsen 2013-03-06 12:15:47 +01:00 committed by Edward Hervey
parent e56efddd4a
commit 8e4f966018

View file

@ -317,7 +317,6 @@ gst_ts_demux_reset (MpegTSBase * base)
{ {
GstTSDemux *demux = (GstTSDemux *) base; GstTSDemux *demux = (GstTSDemux *) base;
demux->program_number = -1;
demux->calculate_update_segment = FALSE; demux->calculate_update_segment = FALSE;
gst_segment_init (&demux->segment, GST_FORMAT_UNDEFINED); 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) */ /* We are not interested in sections (all handled by mpegtsbase) */
base->push_section = FALSE; base->push_section = FALSE;
demux->program_number = -1;
gst_ts_demux_reset (base); gst_ts_demux_reset (base);
} }