From 1d1d4694889fd78534561829ac504425b63ac2ad Mon Sep 17 00:00:00 2001 From: Edward Hervey Date: Mon, 16 Jun 2014 07:42:37 +0200 Subject: tsdemux: Don't overwrite original seek value In accurate mode, we'll be using start to fill in the seek segment, therefore don't overwrite it with the shifted seek position. https://bugzilla.gnome.org/show_bug.cgi?id=731698 --- gst/mpegtsdemux/tsdemux.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'gst') diff --git a/gst/mpegtsdemux/tsdemux.c b/gst/mpegtsdemux/tsdemux.c index ef6055b0e..aa717b437 100644 --- a/gst/mpegtsdemux/tsdemux.c +++ b/gst/mpegtsdemux/tsdemux.c @@ -811,10 +811,9 @@ gst_ts_demux_do_seek (MpegTSBase * base, GstEvent * event) /* configure the segment with the seek variables */ GST_DEBUG_OBJECT (demux, "configuring seek"); - start = MAX (0, start - SEEK_TIMESTAMP_OFFSET); start_offset = - mpegts_packetizer_ts_to_offset (base->packetizer, start, - demux->program->pcr_pid); + mpegts_packetizer_ts_to_offset (base->packetizer, MAX (0, + start - SEEK_TIMESTAMP_OFFSET), demux->program->pcr_pid); if (G_UNLIKELY (start_offset == -1)) { GST_WARNING ("Couldn't convert start position to an offset"); -- cgit v1.2.1