diff options
Diffstat (limited to 'src/transport/test_plugin_transport_http.c')
-rw-r--r-- | src/transport/test_plugin_transport_http.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/src/transport/test_plugin_transport_http.c b/src/transport/test_plugin_transport_http.c index f8b5e4dba..76e4f64f6 100644 --- a/src/transport/test_plugin_transport_http.c +++ b/src/transport/test_plugin_transport_http.c | |||
@@ -36,7 +36,8 @@ | |||
36 | #include "plugin_transport.h" | 36 | #include "plugin_transport.h" |
37 | #include "transport.h" | 37 | #include "transport.h" |
38 | 38 | ||
39 | #define VERBOSE GNUNET_NO | 39 | #define VERBOSE GNUNET_YES |
40 | #define DEBUG GNUNET_YES | ||
40 | 41 | ||
41 | /** | 42 | /** |
42 | * How long until we give up on transmitting the message? | 43 | * How long until we give up on transmitting the message? |
@@ -124,7 +125,7 @@ static void | |||
124 | unload_plugins (void *cls, const struct GNUNET_CONFIGURATION_Handle *cfg) | 125 | unload_plugins (void *cls, const struct GNUNET_CONFIGURATION_Handle *cfg) |
125 | { | 126 | { |
126 | GNUNET_assert (NULL == | 127 | GNUNET_assert (NULL == |
127 | GNUNET_PLUGIN_unload ("libgnunet_plugin_transport_udp", | 128 | GNUNET_PLUGIN_unload ("libgnunet_plugin_transport_http", |
128 | api)); | 129 | api)); |
129 | if (my_private_key != NULL) | 130 | if (my_private_key != NULL) |
130 | GNUNET_CRYPTO_rsa_key_free (my_private_key); | 131 | GNUNET_CRYPTO_rsa_key_free (my_private_key); |
@@ -143,7 +144,6 @@ static void | |||
143 | test_validation () | 144 | test_validation () |
144 | { | 145 | { |
145 | struct sockaddr_in soaddr; | 146 | struct sockaddr_in soaddr; |
146 | |||
147 | memset (&soaddr, 0, sizeof (soaddr)); | 147 | memset (&soaddr, 0, sizeof (soaddr)); |
148 | #if HAVE_SOCKADDR_IN_SIN_LEN | 148 | #if HAVE_SOCKADDR_IN_SIN_LEN |
149 | soaddr.sin_len = sizeof (soaddr); | 149 | soaddr.sin_len = sizeof (soaddr); |
@@ -207,6 +207,7 @@ run (void *cls, | |||
207 | GNUNET_SCHEDULER_shutdown (s); | 207 | GNUNET_SCHEDULER_shutdown (s); |
208 | return; | 208 | return; |
209 | } | 209 | } |
210 | /* | ||
210 | max_connect_per_transport = (uint32_t) tneigh; | 211 | max_connect_per_transport = (uint32_t) tneigh; |
211 | my_private_key = GNUNET_CRYPTO_rsa_key_create_from_file (keyfile); | 212 | my_private_key = GNUNET_CRYPTO_rsa_key_create_from_file (keyfile); |
212 | GNUNET_free (keyfile); | 213 | GNUNET_free (keyfile); |
@@ -220,14 +221,18 @@ run (void *cls, | |||
220 | } | 221 | } |
221 | GNUNET_CRYPTO_rsa_key_get_public (my_private_key, &my_public_key); | 222 | GNUNET_CRYPTO_rsa_key_get_public (my_private_key, &my_public_key); |
222 | GNUNET_CRYPTO_hash (&my_public_key, | 223 | GNUNET_CRYPTO_hash (&my_public_key, |
223 | sizeof (my_public_key), &my_identity.hashPubKey); | 224 | sizeof (my_public_key), &my_identity.hashPubKey);*/ |
224 | 225 | ||
225 | /* load plugins... */ | 226 | /* load plugins... */ |
226 | setup_plugin_environment (); | 227 | setup_plugin_environment (); |
227 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, _("Loading http transport plugin\n")); | 228 | |
228 | GNUNET_asprintf (&libname, "libgnunet_plugin_transport_http"); | 229 | GNUNET_asprintf (&libname, "libgnunet_plugin_transport_http"); |
229 | 230 | ||
230 | api = GNUNET_PLUGIN_load (libname, &env); | 231 | api = GNUNET_PLUGIN_load (libname, &env); |
232 | if (api != NULL ) | ||
233 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
234 | "Loading transport plugin for http `%s' successful\n",libname); | ||
235 | |||
231 | GNUNET_free (libname); | 236 | GNUNET_free (libname); |
232 | if (api == NULL) | 237 | if (api == NULL) |
233 | { | 238 | { |