summaryrefslogtreecommitdiff
path: root/src/transport
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-11-04 21:01:22 +0000
committerChristian Grothoff <christian@grothoff.org>2012-11-04 21:01:22 +0000
commit0e4c7cdccfc4105f9c6e529cfa0e3722104b0ddf (patch)
treeac53b9088e75b7041e14e3455698a75da085b3d7 /src/transport
parentb6d09b511fbd61d3b36fde4c28624bed321bf4a1 (diff)
-misc bugfixes, travel hacking
Diffstat (limited to 'src/transport')
-rw-r--r--src/transport/gnunet-transport.c6
-rw-r--r--src/transport/template_cfg_peer1.conf2
-rw-r--r--src/transport/template_cfg_peer2.conf1
-rw-r--r--src/transport/test_transport_api_bidirectional_connect_peer1.conf1
-rw-r--r--src/transport/test_transport_api_disconnect_tcp_peer1.conf1
-rw-r--r--src/transport/test_transport_api_http_peer1.conf1
-rw-r--r--src/transport/test_transport_api_http_peer2.conf1
-rw-r--r--src/transport/test_transport_api_http_reverse_peer1.conf2
-rw-r--r--src/transport/test_transport_api_https_peer1.conf1
-rw-r--r--src/transport/test_transport_api_https_peer2.conf1
-rw-r--r--src/transport/test_transport_api_reliability_http_peer1.conf1
-rw-r--r--src/transport/test_transport_api_reliability_http_peer2.conf1
-rw-r--r--src/transport/test_transport_api_reliability_tcp_peer2.conf1
-rw-r--r--src/transport/test_transport_api_tcp_nat_peer1.conf1
-rw-r--r--src/transport/test_transport_api_tcp_nat_peer2.conf1
-rw-r--r--src/transport/test_transport_api_tcp_peer1.conf1
-rw-r--r--src/transport/test_transport_api_timeout_http_peer1.conf1
-rw-r--r--src/transport/test_transport_api_timeout_http_peer2.conf1
-rw-r--r--src/transport/test_transport_api_timeout_https_peer1.conf1
-rw-r--r--src/transport/test_transport_api_timeout_https_peer2.conf1
-rw-r--r--src/transport/test_transport_api_udp_nat_peer1.conf1
-rw-r--r--src/transport/test_transport_api_udp_nat_peer2.conf1
-rw-r--r--src/transport/test_transport_api_wlan_peer1.conf2
-rw-r--r--src/transport/test_transport_api_wlan_peer2.conf2
-rw-r--r--src/transport/transport-testing.c15
25 files changed, 6 insertions, 42 deletions
diff --git a/src/transport/gnunet-transport.c b/src/transport/gnunet-transport.c
index 5978de6bb..18b1b9839 100644
--- a/src/transport/gnunet-transport.c
+++ b/src/transport/gnunet-transport.c
@@ -745,13 +745,9 @@ main (int argc, char *const *argv)
("Direct access to transport service."), options,
&run, NULL);
GNUNET_free ((void *) argv);
-
if (GNUNET_OK == res)
return ret;
- else
- return 1;
-
-
+ return 1;
}
diff --git a/src/transport/template_cfg_peer1.conf b/src/transport/template_cfg_peer1.conf
index 05309d53c..8856418b3 100644
--- a/src/transport/template_cfg_peer1.conf
+++ b/src/transport/template_cfg_peer1.conf
@@ -39,11 +39,9 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
[transport]
#PREFIX = valgrind --leak-check=full
PORT = 12001
-#DEBUG = YES
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
[ats]
-#DEBUG = YES
WAN_QUOTA_IN = unlimited
WAN_QUOTA_OUT = unlimited
PORT = 12006
diff --git a/src/transport/template_cfg_peer2.conf b/src/transport/template_cfg_peer2.conf
index 210ee51c5..54636ca6b 100644
--- a/src/transport/template_cfg_peer2.conf
+++ b/src/transport/template_cfg_peer2.conf
@@ -43,7 +43,6 @@ PORT = 12010
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
[ats]
-#DEBUG = YES
WAN_QUOTA_IN = unlimited
WAN_QUOTA_OUT = unlimited
PORT = 12016
diff --git a/src/transport/test_transport_api_bidirectional_connect_peer1.conf b/src/transport/test_transport_api_bidirectional_connect_peer1.conf
index 614d89d21..ba6afbe6e 100644
--- a/src/transport/test_transport_api_bidirectional_connect_peer1.conf
+++ b/src/transport/test_transport_api_bidirectional_connect_peer1.conf
@@ -22,7 +22,6 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
[transport]
PORT = 12004
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
-#DEBUG = YES
[transport-tcp]
PORT = 12005
diff --git a/src/transport/test_transport_api_disconnect_tcp_peer1.conf b/src/transport/test_transport_api_disconnect_tcp_peer1.conf
index 6879d0534..5f1d693a8 100644
--- a/src/transport/test_transport_api_disconnect_tcp_peer1.conf
+++ b/src/transport/test_transport_api_disconnect_tcp_peer1.conf
@@ -27,5 +27,4 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
PORT = 12001
PLUGINS = tcp
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
-#DEBUG = YES
diff --git a/src/transport/test_transport_api_http_peer1.conf b/src/transport/test_transport_api_http_peer1.conf
index e0b60e37f..3c1b41d06 100644
--- a/src/transport/test_transport_api_http_peer1.conf
+++ b/src/transport/test_transport_api_http_peer1.conf
@@ -22,7 +22,6 @@ PORT = 12082
UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
[transport]
-#DEBUG = YES
PORT = 12081
PLUGINS = http_client
#BINARY = .libs/gnunet-service-transport
diff --git a/src/transport/test_transport_api_http_peer2.conf b/src/transport/test_transport_api_http_peer2.conf
index 4e4c22e30..f348bf404 100644
--- a/src/transport/test_transport_api_http_peer2.conf
+++ b/src/transport/test_transport_api_http_peer2.conf
@@ -25,7 +25,6 @@ PORT = 12092
UNIXPATH = /tmp/gnunet-p2-service-peerinfo.sock
[transport]
-#DEBUG = YES
PORT = 12091
PLUGINS = http_server
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
diff --git a/src/transport/test_transport_api_http_reverse_peer1.conf b/src/transport/test_transport_api_http_reverse_peer1.conf
index c38c36a18..93d8bd34b 100644
--- a/src/transport/test_transport_api_http_reverse_peer1.conf
+++ b/src/transport/test_transport_api_http_reverse_peer1.conf
@@ -23,7 +23,6 @@ PORT = 12092
UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
[transport]
-#DEBUG = YES
PORT = 12091
PLUGINS = http_client
#BINARY = .libs/gnunet-service-transport
@@ -33,7 +32,6 @@ PREFIX = valgrind --leak-check=full
[ats]
-#DEBUG = YES
WAN_QUOTA_IN = unlimited
WAN_QUOTA_OUT = unlimited
PORT = 12006
diff --git a/src/transport/test_transport_api_https_peer1.conf b/src/transport/test_transport_api_https_peer1.conf
index 78d3ca0a4..48302a640 100644
--- a/src/transport/test_transport_api_https_peer1.conf
+++ b/src/transport/test_transport_api_https_peer1.conf
@@ -26,6 +26,5 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
PORT = 12101
PLUGINS = https_client
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
-DEBUG = NO
diff --git a/src/transport/test_transport_api_https_peer2.conf b/src/transport/test_transport_api_https_peer2.conf
index a347887bb..566997f93 100644
--- a/src/transport/test_transport_api_https_peer2.conf
+++ b/src/transport/test_transport_api_https_peer2.conf
@@ -29,6 +29,5 @@ UNIXPATH = /tmp/gnunet-p2-service-peerinfo.sock
PORT = 12111
PLUGINS = https_server
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
-DEBUG = NO
diff --git a/src/transport/test_transport_api_reliability_http_peer1.conf b/src/transport/test_transport_api_reliability_http_peer1.conf
index 9e39e3e41..ea5de0bc9 100644
--- a/src/transport/test_transport_api_reliability_http_peer1.conf
+++ b/src/transport/test_transport_api_reliability_http_peer1.conf
@@ -30,5 +30,4 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
PORT = 12181
PLUGINS = http_client
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
-#DEBUG = YES
diff --git a/src/transport/test_transport_api_reliability_http_peer2.conf b/src/transport/test_transport_api_reliability_http_peer2.conf
index 3174e3d00..083cd4dd8 100644
--- a/src/transport/test_transport_api_reliability_http_peer2.conf
+++ b/src/transport/test_transport_api_reliability_http_peer2.conf
@@ -27,5 +27,4 @@ UNIXPATH = /tmp/gnunet-p2-service-peerinfo.sock
PORT = 12191
PLUGINS = http_server
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
-#DEBUG = YES
diff --git a/src/transport/test_transport_api_reliability_tcp_peer2.conf b/src/transport/test_transport_api_reliability_tcp_peer2.conf
index 3cb42c0b6..181aab3de 100644
--- a/src/transport/test_transport_api_reliability_tcp_peer2.conf
+++ b/src/transport/test_transport_api_reliability_tcp_peer2.conf
@@ -27,4 +27,3 @@ UNIXPATH = /tmp/gnunet-p2-service-peerinfo.sock
PORT = 12010
PLUGINS = tcp
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
-#DEBUG = YES
diff --git a/src/transport/test_transport_api_tcp_nat_peer1.conf b/src/transport/test_transport_api_tcp_nat_peer1.conf
index 4ebf5b3be..8e33f273d 100644
--- a/src/transport/test_transport_api_tcp_nat_peer1.conf
+++ b/src/transport/test_transport_api_tcp_nat_peer1.conf
@@ -32,5 +32,4 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
PORT = 29542
PLUGINS = tcp
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
-#DEBUG = YES
diff --git a/src/transport/test_transport_api_tcp_nat_peer2.conf b/src/transport/test_transport_api_tcp_nat_peer2.conf
index 1ef51c9c9..f8b8b013e 100644
--- a/src/transport/test_transport_api_tcp_nat_peer2.conf
+++ b/src/transport/test_transport_api_tcp_nat_peer2.conf
@@ -31,4 +31,3 @@ UNIXPATH = /tmp/gnunet-p2-service-peerinfo.sock
PORT = 45923
PLUGINS = tcp
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
-#DEBUG = YES
diff --git a/src/transport/test_transport_api_tcp_peer1.conf b/src/transport/test_transport_api_tcp_peer1.conf
index 54abfa5ba..db662826b 100644
--- a/src/transport/test_transport_api_tcp_peer1.conf
+++ b/src/transport/test_transport_api_tcp_peer1.conf
@@ -27,5 +27,4 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
PORT = 12001
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
PLUGINS = tcp
-#DEBUG = YES
diff --git a/src/transport/test_transport_api_timeout_http_peer1.conf b/src/transport/test_transport_api_timeout_http_peer1.conf
index 2eb23662a..665527b3e 100644
--- a/src/transport/test_transport_api_timeout_http_peer1.conf
+++ b/src/transport/test_transport_api_timeout_http_peer1.conf
@@ -24,7 +24,6 @@ PORT = 12082
UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
[transport]
-#DEBUG = YES
PORT = 12081
PLUGINS = http_client
#BINARY = .libs/gnunet-service-transport
diff --git a/src/transport/test_transport_api_timeout_http_peer2.conf b/src/transport/test_transport_api_timeout_http_peer2.conf
index 0aa77a9b9..1fdc94788 100644
--- a/src/transport/test_transport_api_timeout_http_peer2.conf
+++ b/src/transport/test_transport_api_timeout_http_peer2.conf
@@ -28,7 +28,6 @@ PORT = 12092
UNIXPATH = /tmp/gnunet-p2-service-peerinfo.sock
[transport]
-#DEBUG = YES
PORT = 12091
PLUGINS = http_server
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
diff --git a/src/transport/test_transport_api_timeout_https_peer1.conf b/src/transport/test_transport_api_timeout_https_peer1.conf
index ff1ef47bd..fda69ae5c 100644
--- a/src/transport/test_transport_api_timeout_https_peer1.conf
+++ b/src/transport/test_transport_api_timeout_https_peer1.conf
@@ -23,6 +23,5 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
PORT = 12101
PLUGINS = https_client
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
-DEBUG = NO
diff --git a/src/transport/test_transport_api_timeout_https_peer2.conf b/src/transport/test_transport_api_timeout_https_peer2.conf
index 35fba0a83..ca54e1718 100644
--- a/src/transport/test_transport_api_timeout_https_peer2.conf
+++ b/src/transport/test_transport_api_timeout_https_peer2.conf
@@ -27,6 +27,5 @@ UNIXPATH = /tmp/gnunet-p2-service-peerinfo.sock
PORT = 12111
PLUGINS = https_server
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
-DEBUG = NO
diff --git a/src/transport/test_transport_api_udp_nat_peer1.conf b/src/transport/test_transport_api_udp_nat_peer1.conf
index 6e643d5af..e406883e4 100644
--- a/src/transport/test_transport_api_udp_nat_peer1.conf
+++ b/src/transport/test_transport_api_udp_nat_peer1.conf
@@ -31,6 +31,5 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
PORT = 12061
PLUGINS = udp
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
-DEBUG = NO
diff --git a/src/transport/test_transport_api_udp_nat_peer2.conf b/src/transport/test_transport_api_udp_nat_peer2.conf
index 1c1258ad1..43ed3a91b 100644
--- a/src/transport/test_transport_api_udp_nat_peer2.conf
+++ b/src/transport/test_transport_api_udp_nat_peer2.conf
@@ -29,6 +29,5 @@ UNIXPATH = /tmp/gnunet-p2-service-peerinfo.sock
PORT = 12071
PLUGINS = udp
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
-DEBUG = NO
diff --git a/src/transport/test_transport_api_wlan_peer1.conf b/src/transport/test_transport_api_wlan_peer1.conf
index ff37415a4..3f12ce505 100644
--- a/src/transport/test_transport_api_wlan_peer1.conf
+++ b/src/transport/test_transport_api_wlan_peer1.conf
@@ -7,7 +7,6 @@ INTERFACE = mon0
TESTMODE = 1
[arm]
-DEBUG = YES
PORT = 12164
UNIXPATH = /tmp/gnunet-p1-service-arm.sock
@@ -26,7 +25,6 @@ UNIXPATH = /tmp/gnunet-p1-service-peerinfo.sock
[transport]
PORT = 12160
PLUGINS = wlan
-#DEBUG = YES
UNIXPATH = /tmp/gnunet-p1-service-transport.sock
#PREFIX = xterm -T transport2 -e gdb --command=cmd --args
#PREFIX = valgrind --leak-check=full --show-reachable=yes --main-stacksize=104857600
diff --git a/src/transport/test_transport_api_wlan_peer2.conf b/src/transport/test_transport_api_wlan_peer2.conf
index 87a6036fb..451a2a666 100644
--- a/src/transport/test_transport_api_wlan_peer2.conf
+++ b/src/transport/test_transport_api_wlan_peer2.conf
@@ -8,7 +8,6 @@ TESTMODE = 2
[arm]
PORT = 12174
-DEBUG = YES
UNIXPATH = /tmp/gnunet-p2-service-arm.sock
[statistics]
@@ -26,7 +25,6 @@ UNIXPATH = /tmp/gnunet-p2-service-peerinfo.sock
[transport]
PORT = 12170
PLUGINS = wlan
-#DEBUG = YES
UNIXPATH = /tmp/gnunet-p2-service-transport.sock
#PREFIX = xterm -T transport2 -e gdb --command=cmd --args
#PREFIX = valgrind --leak-check=full --show-reachable=yes --main-stacksize=104857600
diff --git a/src/transport/transport-testing.c b/src/transport/transport-testing.c
index f1c06ebc0..0c51ef334 100644
--- a/src/transport/transport-testing.c
+++ b/src/transport/transport-testing.c
@@ -71,19 +71,15 @@ notify_connect (void *cls, const struct GNUNET_PeerIdentity *peer,
const struct GNUNET_ATS_Information *ats, uint32_t ats_count)
{
struct PeerContext *p = cls;
+ char *p2_s;
+ struct PeerContext *p2;
- /* Find PeerContext */
- GNUNET_assert (p != 0);
- GNUNET_assert (p->tth != NULL);
- struct PeerContext *p2 = find_peer_context (p->tth, peer);
-
- if (p == NULL)
- return;
+ GNUNET_assert (NULL != p);
+ GNUNET_assert (NULL != p->tth);
+ p2 = find_peer_context (p->tth, peer);
if (p->nc != NULL)
p->nc (p->cb_cls, peer, ats, ats_count);
- char *p2_s;
-
if (p2 != NULL)
GNUNET_asprintf (&p2_s, "%u (`%s')", p2->no, GNUNET_i2s (&p2->id));
else
@@ -788,5 +784,4 @@ fail:
}
-
/* end of transport-testing.c */