[gst-devel] [gst-cvs] gst-plugins-ugly: mpegstream: Remove dead assignments.
Peter Kjellerstedt
peter.kjellerstedt at axis.com
Wed Apr 22 11:27:52 CEST 2009
Could it be that someone had intended to clamp the value?
I.e., something like this:
update_time = CLAMP (timestamp, mpeg_parse->current_segment.start,
mpeg_parse->current_segment.stop);
I have not looked at the surrounding code so I do not know
if it is the case, but it seems plausible.
//Peter
> -----Original Message-----
> From: Edward Hervey [mailto:bilboed at kemper.freedesktop.org]
> Sent: den 21 april 2009 20:41
> To: gstreamer-cvs at lists.sourceforge.net
> Subject: [gst-cvs] gst-plugins-ugly: mpegstream: Remove dead
> assignments.
>
> Module: gst-plugins-ugly
> Branch: master
> Commit: df349f9359d0154ca44bc129e6062a61b68cfba3
> URL: http://cgit.freedesktop.org/gstreamer/gst-plugins-
> ugly/commit/?id=df349f9359d0154ca44bc129e6062a61b68cfba3
>
> Author: Edward Hervey <bilboed at bilboed.com>
> Date: Tue Apr 21 20:20:02 2009 +0200
>
> 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 b867807..c8d55d8 100644
> --- a/gst/mpegstream/gstmpegdemux.c
> +++ b/gst/mpegstream/gstmpegdemux.c
> @@ -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) {
More information about the gstreamer-devel
mailing list