diff options
Diffstat (limited to 'src/transport/plugin_transport_udp_broadcasting.c')
-rw-r--r-- | src/transport/plugin_transport_udp_broadcasting.c | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/src/transport/plugin_transport_udp_broadcasting.c b/src/transport/plugin_transport_udp_broadcasting.c index d378f2663..623cde2bd 100644 --- a/src/transport/plugin_transport_udp_broadcasting.c +++ b/src/transport/plugin_transport_udp_broadcasting.c | |||
@@ -105,12 +105,10 @@ broadcast_ipv6_mst_cb (void *cls, void *client, | |||
105 | if (GNUNET_MESSAGE_TYPE_TRANSPORT_BROADCAST_BEACON != | 105 | if (GNUNET_MESSAGE_TYPE_TRANSPORT_BROADCAST_BEACON != |
106 | ntohs (msg->header.type)) | 106 | ntohs (msg->header.type)) |
107 | return; | 107 | return; |
108 | #if DEBUG_UDP_BROADCASTING | ||
109 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 108 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
110 | "Received beacon with %u bytes from peer `%s' via address `%s'\n", | 109 | "Received beacon with %u bytes from peer `%s' via address `%s'\n", |
111 | ntohs (msg->header.size), GNUNET_i2s (&msg->sender), | 110 | ntohs (msg->header.size), GNUNET_i2s (&msg->sender), |
112 | udp_address_to_string (NULL, &mc->addr, sizeof (mc->addr))); | 111 | udp_address_to_string (NULL, &mc->addr, sizeof (mc->addr))); |
113 | #endif | ||
114 | struct GNUNET_ATS_Information atsi[2]; | 112 | struct GNUNET_ATS_Information atsi[2]; |
115 | 113 | ||
116 | /* setup ATS */ | 114 | /* setup ATS */ |
@@ -146,12 +144,10 @@ broadcast_ipv4_mst_cb (void *cls, void *client, | |||
146 | if (GNUNET_MESSAGE_TYPE_TRANSPORT_BROADCAST_BEACON != | 144 | if (GNUNET_MESSAGE_TYPE_TRANSPORT_BROADCAST_BEACON != |
147 | ntohs (msg->header.type)) | 145 | ntohs (msg->header.type)) |
148 | return; | 146 | return; |
149 | #if DEBUG_UDP_BROADCASTING | ||
150 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 147 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
151 | "Received beacon with %u bytes from peer `%s' via address `%s'\n", | 148 | "Received beacon with %u bytes from peer `%s' via address `%s'\n", |
152 | ntohs (msg->header.size), GNUNET_i2s (&msg->sender), | 149 | ntohs (msg->header.size), GNUNET_i2s (&msg->sender), |
153 | udp_address_to_string (NULL, &mc->addr, sizeof (mc->addr))); | 150 | udp_address_to_string (NULL, &mc->addr, sizeof (mc->addr))); |
154 | #endif | ||
155 | 151 | ||
156 | struct GNUNET_ATS_Information atsi[2]; | 152 | struct GNUNET_ATS_Information atsi[2]; |
157 | 153 | ||
@@ -181,11 +177,9 @@ udp_broadcast_receive (struct Plugin *plugin, const char * buf, ssize_t size, st | |||
181 | 177 | ||
182 | if (addrlen == sizeof (struct sockaddr_in)) | 178 | if (addrlen == sizeof (struct sockaddr_in)) |
183 | { | 179 | { |
184 | #if DEBUG_UDP_BROADCASTING | ||
185 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 180 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
186 | "Received IPv4 HELLO beacon broadcast with %i bytes from address %s\n", | 181 | "Received IPv4 HELLO beacon broadcast with %i bytes from address %s\n", |
187 | size, GNUNET_a2s ((const struct sockaddr *) addr, addrlen)); | 182 | size, GNUNET_a2s ((const struct sockaddr *) addr, addrlen)); |
188 | #endif | ||
189 | struct Mstv4Context *mc; | 183 | struct Mstv4Context *mc; |
190 | 184 | ||
191 | mc = GNUNET_malloc (sizeof (struct Mstv4Context)); | 185 | mc = GNUNET_malloc (sizeof (struct Mstv4Context)); |
@@ -202,11 +196,9 @@ udp_broadcast_receive (struct Plugin *plugin, const char * buf, ssize_t size, st | |||
202 | } | 196 | } |
203 | else if (addrlen == sizeof (struct sockaddr_in6)) | 197 | else if (addrlen == sizeof (struct sockaddr_in6)) |
204 | { | 198 | { |
205 | #if DEBUG_UDP_BROADCASTING | ||
206 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 199 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
207 | "Received IPv6 HELLO beacon broadcast with %i bytes from address %s\n", | 200 | "Received IPv6 HELLO beacon broadcast with %i bytes from address %s\n", |
208 | size, GNUNET_a2s ((const struct sockaddr *) &addr, addrlen)); | 201 | size, GNUNET_a2s ((const struct sockaddr *) &addr, addrlen)); |
209 | #endif | ||
210 | struct Mstv6Context *mc; | 202 | struct Mstv6Context *mc; |
211 | 203 | ||
212 | mc = GNUNET_malloc (sizeof (struct Mstv6Context)); | 204 | mc = GNUNET_malloc (sizeof (struct Mstv6Context)); |
@@ -329,7 +321,6 @@ iface_proc (void *cls, const char *name, int isDefault, | |||
329 | 321 | ||
330 | if (addr != NULL) | 322 | if (addr != NULL) |
331 | { | 323 | { |
332 | #if DEBUG_UDP_BROADCASTING | ||
333 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "address %s for interface %s %p\n ", | 324 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "address %s for interface %s %p\n ", |
334 | GNUNET_a2s (addr, addrlen), name, addr); | 325 | GNUNET_a2s (addr, addrlen), name, addr); |
335 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 326 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -337,7 +328,6 @@ iface_proc (void *cls, const char *name, int isDefault, | |||
337 | GNUNET_a2s (broadcast_addr, addrlen), name, broadcast_addr); | 328 | GNUNET_a2s (broadcast_addr, addrlen), name, broadcast_addr); |
338 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "netmask %s for interface %s %p\n ", | 329 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "netmask %s for interface %s %p\n ", |
339 | GNUNET_a2s (netmask, addrlen), name, netmask); | 330 | GNUNET_a2s (netmask, addrlen), name, netmask); |
340 | #endif | ||
341 | 331 | ||
342 | /* Collecting broadcast addresses */ | 332 | /* Collecting broadcast addresses */ |
343 | if (broadcast_addr != NULL) | 333 | if (broadcast_addr != NULL) |
@@ -430,9 +420,7 @@ setup_broadcast (struct Plugin *plugin, struct sockaddr_in6 *serverAddrv6, struc | |||
430 | } | 420 | } |
431 | else | 421 | else |
432 | { | 422 | { |
433 | #if DEBUG_UDP | ||
434 | LOG (GNUNET_ERROR_TYPE_DEBUG, "IPv6 broadcasting running\n"); | 423 | LOG (GNUNET_ERROR_TYPE_DEBUG, "IPv6 broadcasting running\n"); |
435 | #endif | ||
436 | plugin->send_ipv6_broadcast_task = | 424 | plugin->send_ipv6_broadcast_task = |
437 | GNUNET_SCHEDULER_add_now (&udp_ipv6_broadcast_send, plugin); | 425 | GNUNET_SCHEDULER_add_now (&udp_ipv6_broadcast_send, plugin); |
438 | plugin->broadcast_ipv6 = GNUNET_YES; | 426 | plugin->broadcast_ipv6 = GNUNET_YES; |
@@ -483,9 +471,7 @@ stop_broadcast (struct Plugin *plugin) | |||
483 | } | 471 | } |
484 | else | 472 | else |
485 | { | 473 | { |
486 | #if DEBUG_UDP | ||
487 | LOG (GNUNET_ERROR_TYPE_DEBUG, "IPv6 Broadcasting stopped\n"); | 474 | LOG (GNUNET_ERROR_TYPE_DEBUG, "IPv6 Broadcasting stopped\n"); |
488 | #endif | ||
489 | } | 475 | } |
490 | 476 | ||
491 | if (plugin->send_ipv6_broadcast_task != GNUNET_SCHEDULER_NO_TASK) | 477 | if (plugin->send_ipv6_broadcast_task != GNUNET_SCHEDULER_NO_TASK) |