summaryrefslogtreecommitdiffstats
path: root/gst/udp/gstmultiudpsink.c
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim@centricular.net>2008-04-25 13:31:48 +0000
committerTim-Philipp Müller <tim@centricular.net>2008-04-25 13:31:48 +0000
commit327741a21a1b1fcadc37e3aa1f294b12d8ba8f30 (patch)
tree86cf2cb7c9fd877bcc40ff7c85ac5d188bb2ac86 /gst/udp/gstmultiudpsink.c
parent883d93df58691c941822e2ca9077a7c23fb74492 (diff)
gst/: Use GLib versions of htonl, htons, ntohl and ntohs in order to avoid problems on win32 (#529707).
Original commit message from CVS: * gst/rtp/gstasteriskh263.c: (gst_asteriskh263_chain): * gst/udp/gstmultiudpsink.c: (gst_multiudpsink_add_internal): * gst/udp/gstudpsrc.c: (gst_udpsrc_start): Use GLib versions of htonl, htons, ntohl and ntohs in order to avoid problems on win32 (#529707).
Diffstat (limited to 'gst/udp/gstmultiudpsink.c')
-rw-r--r--gst/udp/gstmultiudpsink.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gst/udp/gstmultiudpsink.c b/gst/udp/gstmultiudpsink.c
index 1ec8f63a..6c23874a 100644
--- a/gst/udp/gstmultiudpsink.c
+++ b/gst/udp/gstmultiudpsink.c
@@ -626,7 +626,7 @@ gst_multiudpsink_add_internal (GstMultiUDPSink * sink, const gchar * host,
memset (&client->theiraddr, 0, sizeof (client->theiraddr));
memset (&client->multi_addr, 0, sizeof (client->multi_addr));
client->theiraddr.sin_family = AF_INET; /* host byte order */
- client->theiraddr.sin_port = htons (port); /* short, network byte order */
+ client->theiraddr.sin_port = g_htons (port); /* short, network byte order */
g_get_current_time (&now);
client->connect_time = GST_TIMEVAL_TO_TIME (now);
@@ -634,7 +634,7 @@ gst_multiudpsink_add_internal (GstMultiUDPSink * sink, const gchar * host,
/* if its an IP address */
if (inet_aton (host, &addr)) {
/* check if its a multicast address */
- if ((ntohl (addr.s_addr) & 0xf0000000) == 0xe0000000) {
+ if ((g_ntohl (addr.s_addr) & 0xf0000000) == 0xe0000000) {
GST_DEBUG_OBJECT (sink, "multicast address detected");
client->multi_addr.imr_multiaddr.s_addr = addr.s_addr;
client->multi_addr.imr_interface.s_addr = INADDR_ANY;