[gst-cvs] gstreamer: netclientclock: fix timestamp comparission, Fixes #597407
Stefan Kost
ensonic at kemper.freedesktop.org
Tue Oct 13 09:18:28 PDT 2009
Module: gstreamer
Branch: master
Commit: 87058ab28eac53a071d55b7b6a589ec2ea6759f2
URL: http://cgit.freedesktop.org/gstreamer/gstreamer/commit/?id=87058ab28eac53a071d55b7b6a589ec2ea6759f2
Author: Tommi Myöhänen <ext-tommi.1.myohanen at nokia.com>
Date: Tue Oct 13 19:12:50 2009 +0300
netclientclock: fix timestamp comparission, Fixes #597407
---
libs/gst/net/gstnetclientclock.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/libs/gst/net/gstnetclientclock.c b/libs/gst/net/gstnetclientclock.c
index c45231c..c1f19b3 100644
--- a/libs/gst/net/gstnetclientclock.c
+++ b/libs/gst/net/gstnetclientclock.c
@@ -557,8 +557,10 @@ gst_net_client_clock_new (gchar * name, const gchar * remote_address,
{
GstClockTime now = gst_clock_get_time (GST_CLOCK (ret));
- if (now < base_time || now > base_time + GST_SECOND)
+ if (GST_CLOCK_DIFF (now, base_time) > 0 ||
+ GST_CLOCK_DIFF (now, base_time + GST_SECOND) < 0) {
g_warning ("unable to set the base time, expect sync problems!");
+ }
}
if ((ret->priv->fdset = gst_poll_new (TRUE)) == NULL)
More information about the Gstreamer-commits
mailing list