From df349f9359d0154ca44bc129e6062a61b68cfba3 Mon Sep 17 00:00:00 2001 From: Edward Hervey Date: Tue, 21 Apr 2009 20:20:02 +0200 Subject: [PATCH] mpegstream: Remove dead assignments. The duplicate assignment of update_time was weird... but it seems normal that it's indeed the second statement which is the valid one. --- gst/mpegstream/gstmpegdemux.c | 7 ++----- gst/mpegstream/gstmpegparse.c | 1 - 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/gst/mpegstream/gstmpegdemux.c b/gst/mpegstream/gstmpegdemux.c index b867807aa2..c8d55d8384 100644 --- a/gst/mpegstream/gstmpegdemux.c +++ b/gst/mpegstream/gstmpegdemux.c @@ -504,11 +504,9 @@ static gboolean gst_mpeg_demux_parse_packhead (GstMPEGParse * mpeg_parse, GstBuffer * buffer) { GstMPEGDemux *demux = GST_MPEG_DEMUX (mpeg_parse); - guint8 *buf; parent_class->parse_packhead (mpeg_parse, buffer); - buf = GST_BUFFER_DATA (buffer); /* do something useful here */ if (demux->pending_tags) { @@ -653,12 +651,12 @@ gst_mpeg_demux_parse_packet (GstMPEGParse * mpeg_parse, GstBuffer * buffer) guint16 datalen; GstMPEGStream *outstream = NULL; - guint8 *buf, *basebuf; + guint8 *buf; gint64 timestamp; GstFlowReturn ret = GST_FLOW_OK; - basebuf = buf = GST_BUFFER_DATA (buffer); + buf = GST_BUFFER_DATA (buffer); id = *(buf + 3); buf += 4; @@ -1072,7 +1070,6 @@ gst_mpeg_demux_send_subbuffer (GstMPEGDemux * mpeg_demux, GstClockTimeDiff diff; guint64 update_time; - update_time = MIN (timestamp, mpeg_parse->current_segment.stop); update_time = MAX (timestamp, mpeg_parse->current_segment.start); diff = GST_CLOCK_DIFF (mpeg_parse->current_segment.last_stop, update_time); if (diff > GST_SECOND * 2) { diff --git a/gst/mpegstream/gstmpegparse.c b/gst/mpegstream/gstmpegparse.c index 83c64e9e97..775f0e7b4a 100644 --- a/gst/mpegstream/gstmpegparse.c +++ b/gst/mpegstream/gstmpegparse.c @@ -1030,7 +1030,6 @@ gst_mpeg_parse_handle_src_query (GstPad * pad, GstQuery * query) src_format = GST_FORMAT_TIME; if (gst_pad_query_peer_duration (mpeg_parse->sinkpad, &src_format, &src_value)) { - res = TRUE; break; } /* Otherwise fallthrough */