summaryrefslogtreecommitdiff
path: root/src/transport
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-11-14 12:06:18 +0000
committerChristian Grothoff <christian@grothoff.org>2013-11-14 12:06:18 +0000
commit9df4cb72d3e3b914caa8e1dc451519715a360026 (patch)
treef020046b369296c67e0835cafbb4b3bfe643463c /src/transport
parent3ab14ab0253aeb1e715caad470e8f308c8243cdf (diff)
-make buildbots happier
Diffstat (limited to 'src/transport')
-rw-r--r--src/transport/plugin_transport_udp.c4
-rw-r--r--src/transport/plugin_transport_udp.h26
-rw-r--r--src/transport/plugin_transport_udp_broadcasting.c13
3 files changed, 29 insertions, 14 deletions
diff --git a/src/transport/plugin_transport_udp.c b/src/transport/plugin_transport_udp.c
index f5086b070..d69390055 100644
--- a/src/transport/plugin_transport_udp.c
+++ b/src/transport/plugin_transport_udp.c
@@ -2438,7 +2438,7 @@ udp_select_read (struct Plugin *plugin, struct GNUNET_NETWORK_Handle *rsock)
switch (ntohs (msg->type))
{
case GNUNET_MESSAGE_TYPE_TRANSPORT_BROADCAST_BEACON:
- udp_broadcast_receive (plugin, &buf, size, addr, fromlen);
+ udp_broadcast_receive (plugin, buf, size, addr, fromlen);
return;
case GNUNET_MESSAGE_TYPE_TRANSPORT_UDP_MESSAGE:
@@ -2905,7 +2905,7 @@ setup_sockets (struct Plugin *plugin,
sockets_created++;
}
else
- {
+ {
LOG (GNUNET_ERROR_TYPE_ERROR,
"Failed to bind UDP socket to %s: %s\n",
GNUNET_a2s (server_addr, addrlen), STRERROR (eno));
diff --git a/src/transport/plugin_transport_udp.h b/src/transport/plugin_transport_udp.h
index 46cea2d5b..fe5a47285 100644
--- a/src/transport/plugin_transport_udp.h
+++ b/src/transport/plugin_transport_udp.h
@@ -57,10 +57,10 @@ GNUNET_NETWORK_STRUCT_BEGIN
*/
struct IPv4UdpAddress
{
- /**
- * Optional options and flags for this address
- */
- uint32_t options GNUNET_PACKED;
+ /**
+ * Optional options and flags for this address
+ */
+ uint32_t options GNUNET_PACKED;
/**
* IPv4 address, in network byte order.
@@ -79,10 +79,10 @@ struct IPv4UdpAddress
*/
struct IPv6UdpAddress
{
- /**
- * Optional options and flags for this address
- */
- uint32_t options GNUNET_PACKED;
+ /**
+ * Optional options and flags for this address
+ */
+ uint32_t options GNUNET_PACKED;
/**
* IPv6 address.
@@ -296,10 +296,16 @@ const char *
udp_address_to_string (void *cls, const void *addr, size_t addrlen);
void
-udp_broadcast_receive ();
+udp_broadcast_receive (struct Plugin *plugin,
+ const char * buf,
+ ssize_t size,
+ const struct sockaddr *addr,
+ size_t addrlen);
void
-setup_broadcast (struct Plugin *plugin, struct sockaddr_in6 *server_addrv6, struct sockaddr_in *server_addrv4);
+setup_broadcast (struct Plugin *plugin,
+ struct sockaddr_in6 *server_addrv6,
+ struct sockaddr_in *server_addrv4);
void
stop_broadcast (struct Plugin *plugin);
diff --git a/src/transport/plugin_transport_udp_broadcasting.c b/src/transport/plugin_transport_udp_broadcasting.c
index 25c942de2..8c42e374f 100644
--- a/src/transport/plugin_transport_udp_broadcasting.c
+++ b/src/transport/plugin_transport_udp_broadcasting.c
@@ -187,8 +187,13 @@ broadcast_ipv4_mst_cb (void *cls, void *client,
return GNUNET_OK;
}
+
void
-udp_broadcast_receive (struct Plugin *plugin, const char * buf, ssize_t size, struct sockaddr *addr, size_t addrlen)
+udp_broadcast_receive (struct Plugin *plugin,
+ const char * buf,
+ ssize_t size,
+ const struct sockaddr *addr,
+ size_t addrlen)
{
struct GNUNET_ATS_Information ats;
@@ -235,6 +240,7 @@ udp_broadcast_receive (struct Plugin *plugin, const char * buf, ssize_t size, st
}
}
+
static unsigned int
prepare_beacon (struct Plugin *plugin, struct UDP_Beacon_Message *msg)
{
@@ -259,6 +265,7 @@ prepare_beacon (struct Plugin *plugin, struct UDP_Beacon_Message *msg)
return msg_size;
}
+
static void
udp_ipv4_broadcast_send (void *cls,
const struct GNUNET_SCHEDULER_TaskContext *tc)
@@ -312,6 +319,7 @@ udp_ipv4_broadcast_send (void *cls,
&udp_ipv4_broadcast_send, plugin);
}
+
static void
udp_ipv6_broadcast_send (void *cls,
const struct GNUNET_SCHEDULER_TaskContext *tc)
@@ -421,7 +429,7 @@ setup_broadcast (struct Plugin *plugin, struct sockaddr_in6 *server_addrv6, stru
}
else
{
- GNUNET_OS_network_interfaces_list (iface_proc, plugin);
+ GNUNET_OS_network_interfaces_list (&iface_proc, plugin);
plugin->send_ipv4_broadcast_task =
GNUNET_SCHEDULER_add_now (&udp_ipv4_broadcast_send, plugin);
@@ -484,6 +492,7 @@ setup_broadcast (struct Plugin *plugin, struct sockaddr_in6 *server_addrv6, stru
}
}
+
void
stop_broadcast (struct Plugin *plugin)
{