GNOME Bugzilla – Bug 697608
netclientclock: gst_net_client_clock_start() always fails on windows
Last modified: 2013-04-09 18:40:18 UTC
gst_net_client_clock_start() does this: socket = g_socket_new (G_SOCKET_FAMILY_IPV4, G_SOCKET_TYPE_DATAGRAM, G_SOCKET_PROTOCOL_UDP, &error); if (socket == NULL) goto no_socket; /* check address we're bound to, mostly for debugging purposes */ myaddr = g_socket_get_local_address (socket, &error); if (myaddr == NULL) goto getsockname_error; ... getsockname_error: { GST_ERROR_OBJECT (self, "get_local_address() failed: %s", error->message); g_error_free (error); g_object_unref (socket); return FALSE; } g_socket_get_local_address() always fails on unbound sockets (and this socket is unbound), so gst_net_client_clock_start() always fails.
Created attachment 241037 [details] [review] netclientclock: bind socket before querying local address Does this help?
_should_ it be bound at all? The comment states that address is mostly for debugging...
I think so. We want to receive packets back from the time provider after all. Maybe on *nix the udp socket gets bound automatically. Could you test it?
Comment on attachment 241037 [details] [review] netclientclock: bind socket before querying local address That changes is correct in any case, I'm surprised it works with the other order on Linux :)
commit 6e5405e9ce7465c1cc441debc8164a9b842699ed Author: Tim-Philipp Müller <tim@centricular.net> Date: Tue Apr 9 10:17:45 2013 +0100 netclientclock: bind socket before querying local address Fails on windows otherwise. https://bugzilla.gnome.org/show_bug.cgi?id=697608