aboutsummaryrefslogtreecommitdiff
path: root/src/transport
diff options
context:
space:
mode:
authorMatthias Wachs <wachs@net.in.tum.de>2013-07-12 14:56:09 +0000
committerMatthias Wachs <wachs@net.in.tum.de>2013-07-12 14:56:09 +0000
commitd59a3ba5d604cd8355a231c34ce5e92b7af56a3b (patch)
treec0e6c86022bf23ac67c952ebd55163db265eb153 /src/transport
parent370a96e8b0a1b0864b88bec3535ac1781ee963d0 (diff)
downloadgnunet-d59a3ba5d604cd8355a231c34ce5e92b7af56a3b.tar.gz
gnunet-d59a3ba5d604cd8355a231c34ce5e92b7af56a3b.zip
using inbound string
Diffstat (limited to 'src/transport')
-rw-r--r--src/transport/gnunet-service-transport.c4
-rw-r--r--src/transport/gnunet-service-transport_plugins.c2
-rw-r--r--src/transport/plugin_transport_http_common.c2
-rw-r--r--src/transport/plugin_transport_tcp.c4
-rw-r--r--src/transport/plugin_transport_udp.c4
-rw-r--r--src/transport/plugin_transport_unix.c4
6 files changed, 10 insertions, 10 deletions
diff --git a/src/transport/gnunet-service-transport.c b/src/transport/gnunet-service-transport.c
index a972999d6..0039b9a4c 100644
--- a/src/transport/gnunet-service-transport.c
+++ b/src/transport/gnunet-service-transport.c
@@ -247,14 +247,14 @@ GST_receive_callback (void *cls, const struct GNUNET_PeerIdentity *peer,
247 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG | GNUNET_ERROR_TYPE_BULK, 247 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG | GNUNET_ERROR_TYPE_BULK,
248 "Processing `%s' from `%s'\n", "PING", 248 "Processing `%s' from `%s'\n", "PING",
249 (sender_address != 249 (sender_address !=
250 NULL) ? GST_plugins_a2s (&address) : "<inbound>"); 250 NULL) ? GST_plugins_a2s (&address) : TRANSPORT_SESSION_INBOUND_STRING);
251 GST_validation_handle_ping (peer, message, &address, session); 251 GST_validation_handle_ping (peer, message, &address, session);
252 break; 252 break;
253 case GNUNET_MESSAGE_TYPE_TRANSPORT_PONG: 253 case GNUNET_MESSAGE_TYPE_TRANSPORT_PONG:
254 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG | GNUNET_ERROR_TYPE_BULK, 254 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG | GNUNET_ERROR_TYPE_BULK,
255 "Processing `%s' from `%s'\n", "PONG", 255 "Processing `%s' from `%s'\n", "PONG",
256 (sender_address != 256 (sender_address !=
257 NULL) ? GST_plugins_a2s (&address) : "<inbound>"); 257 NULL) ? GST_plugins_a2s (&address) : TRANSPORT_SESSION_INBOUND_STRING);
258 GST_validation_handle_pong (peer, message); 258 GST_validation_handle_pong (peer, message);
259 break; 259 break;
260 case GNUNET_MESSAGE_TYPE_TRANSPORT_SESSION_CONNECT: 260 case GNUNET_MESSAGE_TYPE_TRANSPORT_SESSION_CONNECT:
diff --git a/src/transport/gnunet-service-transport_plugins.c b/src/transport/gnunet-service-transport_plugins.c
index 9a55ac919..4d162cf1f 100644
--- a/src/transport/gnunet-service-transport_plugins.c
+++ b/src/transport/gnunet-service-transport_plugins.c
@@ -330,7 +330,7 @@ GST_plugins_a2s (const struct GNUNET_HELLO_Address *address)
330 return "<invalid>"; 330 return "<invalid>";
331 } 331 }
332 if (0 == address->address_length) 332 if (0 == address->address_length)
333 return "<inbound>"; /* Addresse with length 0 are inbound, address->address itself may be NULL */ 333 return TRANSPORT_SESSION_INBOUND_STRING; /* Addresse with length 0 are inbound, address->address itself may be NULL */
334 api = GST_plugins_printer_find (address->transport_name); 334 api = GST_plugins_printer_find (address->transport_name);
335 if (NULL == api) 335 if (NULL == api)
336 return "<plugin unknown>"; 336 return "<plugin unknown>";
diff --git a/src/transport/plugin_transport_http_common.c b/src/transport/plugin_transport_http_common.c
index 887aa6981..4c64d2bf7 100644
--- a/src/transport/plugin_transport_http_common.c
+++ b/src/transport/plugin_transport_http_common.c
@@ -271,7 +271,7 @@ http_common_plugin_address_to_string (void *cls, char *plugin, const void *addr,
271 if (NULL == addr) 271 if (NULL == addr)
272 return NULL; 272 return NULL;
273 if (0 == addrlen) 273 if (0 == addrlen)
274 return "<inbound>"; 274 return TRANSPORT_SESSION_INBOUND_STRING;
275 if (addrlen != http_common_address_get_size (address)) 275 if (addrlen != http_common_address_get_size (address))
276 return NULL; 276 return NULL;
277 addr_str = (char *) &address[1]; 277 addr_str = (char *) &address[1];
diff --git a/src/transport/plugin_transport_tcp.c b/src/transport/plugin_transport_tcp.c
index 9b2ee482e..85b91ecad 100644
--- a/src/transport/plugin_transport_tcp.c
+++ b/src/transport/plugin_transport_tcp.c
@@ -619,7 +619,7 @@ tcp_address_to_string (void *cls, const void *addr, size_t addrlen)
619 case 0: 619 case 0:
620 { 620 {
621 GNUNET_snprintf (rbuf, sizeof (rbuf), "%s", 621 GNUNET_snprintf (rbuf, sizeof (rbuf), "%s",
622 "<inbound>"); 622 TRANSPORT_SESSION_INBOUND_STRING);
623 return rbuf; 623 return rbuf;
624 } 624 }
625 default: 625 default:
@@ -1682,7 +1682,7 @@ tcp_plugin_address_pretty_printer (void *cls, const char *type,
1682 } 1682 }
1683 else if (0 == addrlen) 1683 else if (0 == addrlen)
1684 { 1684 {
1685 asc (asc_cls, "<inbound>"); 1685 asc (asc_cls, TRANSPORT_SESSION_INBOUND_STRING);
1686 asc (asc_cls, NULL); 1686 asc (asc_cls, NULL);
1687 return; 1687 return;
1688 } 1688 }
diff --git a/src/transport/plugin_transport_udp.c b/src/transport/plugin_transport_udp.c
index f4630c071..421da9812 100644
--- a/src/transport/plugin_transport_udp.c
+++ b/src/transport/plugin_transport_udp.c
@@ -549,7 +549,7 @@ udp_address_to_string (void *cls, const void *addr, size_t addrlen)
549 } 549 }
550 else if (addrlen == 0) 550 else if (addrlen == 0)
551 { 551 {
552 GNUNET_snprintf (rbuf, sizeof (rbuf), "%s", "<inbound>"); 552 GNUNET_snprintf (rbuf, sizeof (rbuf), "%s", TRANSPORT_SESSION_INBOUND_STRING);
553 return rbuf; 553 return rbuf;
554 } 554 }
555 else 555 else
@@ -764,7 +764,7 @@ udp_plugin_address_pretty_printer (void *cls, const char *type,
764 } 764 }
765 else if (0 == addrlen) 765 else if (0 == addrlen)
766 { 766 {
767 asc (asc_cls, "<inbound connection>"); 767 asc (asc_cls, TRANSPORT_SESSION_INBOUND_STRING);
768 asc (asc_cls, NULL); 768 asc (asc_cls, NULL);
769 return; 769 return;
770 } 770 }
diff --git a/src/transport/plugin_transport_unix.c b/src/transport/plugin_transport_unix.c
index 3f64e5c19..afa19d0e8 100644
--- a/src/transport/plugin_transport_unix.c
+++ b/src/transport/plugin_transport_unix.c
@@ -1292,7 +1292,7 @@ unix_address_to_string (void *cls, const void *addr, size_t addrlen)
1292 1292
1293 if (0 == addrlen) 1293 if (0 == addrlen)
1294 { 1294 {
1295 GNUNET_snprintf(rbuf, sizeof (rbuf), "%s", "<inbound>"); 1295 GNUNET_snprintf(rbuf, sizeof (rbuf), "%s", TRANSPORT_SESSION_INBOUND_STRING);
1296 } 1296 }
1297 if ((NULL == addr) || (sizeof (struct UnixAddress) > addrlen)) 1297 if ((NULL == addr) || (sizeof (struct UnixAddress) > addrlen))
1298 { 1298 {
@@ -1399,7 +1399,7 @@ unix_plugin_address_pretty_printer (void *cls, const char *type,
1399 } 1399 }
1400 else if (0 == addrlen) 1400 else if (0 == addrlen)
1401 { 1401 {
1402 asc (asc_cls, "<inbound>"); 1402 asc (asc_cls, TRANSPORT_SESSION_INBOUND_STRING);
1403 } 1403 }
1404 else 1404 else
1405 { 1405 {