aboutsummaryrefslogtreecommitdiff
path: root/src/transport/plugin_transport_http.c
diff options
context:
space:
mode:
authorMatthias Wachs <wachs@net.in.tum.de>2010-09-09 09:53:06 +0000
committerMatthias Wachs <wachs@net.in.tum.de>2010-09-09 09:53:06 +0000
commit774871023c74dccb7c9514493cf358785667ed85 (patch)
tree4b3c63b0590230d1fb4d45d4ab521067d0f07543 /src/transport/plugin_transport_http.c
parent0da6349b297bfb66a1314964100fbb9c07887415 (diff)
downloadgnunet-774871023c74dccb7c9514493cf358785667ed85.tar.gz
gnunet-774871023c74dccb7c9514493cf358785667ed85.zip
Diffstat (limited to 'src/transport/plugin_transport_http.c')
-rw-r--r--src/transport/plugin_transport_http.c16
1 files changed, 11 insertions, 5 deletions
diff --git a/src/transport/plugin_transport_http.c b/src/transport/plugin_transport_http.c
index 86fde4a64..775b260c7 100644
--- a/src/transport/plugin_transport_http.c
+++ b/src/transport/plugin_transport_http.c
@@ -2461,6 +2461,11 @@ libgnunet_plugin_transport_http_done (void *cls)
2461 GNUNET_free_non_null (plugin->bind4_address); 2461 GNUNET_free_non_null (plugin->bind4_address);
2462 GNUNET_free_non_null (plugin->bind6_address); 2462 GNUNET_free_non_null (plugin->bind6_address);
2463 GNUNET_free_non_null(plugin->bind_hostname); 2463 GNUNET_free_non_null(plugin->bind_hostname);
2464#if BUILD_HTTPS
2465 GNUNET_free_non_null (plugin->crypto_init);
2466 GNUNET_free_non_null (plugin->cert);
2467 GNUNET_free_non_null (plugin->key);
2468#endif
2464 GNUNET_free (plugin); 2469 GNUNET_free (plugin);
2465 GNUNET_free (api); 2470 GNUNET_free (api);
2466#if DEBUG_HTTP 2471#if DEBUG_HTTP
@@ -2543,7 +2548,7 @@ LIBGNUNET_PLUGIN_TRANSPORT_INIT (void *cls)
2543 /* Hashing our identity to use it in URLs */ 2548 /* Hashing our identity to use it in URLs */
2544 GNUNET_CRYPTO_hash_to_enc ( &(plugin->env->my_identity->hashPubKey), &plugin->my_ascii_hash_ident); 2549 GNUNET_CRYPTO_hash_to_enc ( &(plugin->env->my_identity->hashPubKey), &plugin->my_ascii_hash_ident);
2545 2550
2546 /* Reading port number from config file */ 2551 /* Use IPv6? */
2547 if (GNUNET_CONFIGURATION_have_value (env->cfg, 2552 if (GNUNET_CONFIGURATION_have_value (env->cfg,
2548 component_name, "USE_IPv6")) 2553 component_name, "USE_IPv6"))
2549 { 2554 {
@@ -2551,7 +2556,7 @@ LIBGNUNET_PLUGIN_TRANSPORT_INIT (void *cls)
2551 component_name, 2556 component_name,
2552 "USE_IPv6"); 2557 "USE_IPv6");
2553 } 2558 }
2554 /* Reading port number from config file */ 2559 /* Use IPv4? */
2555 if (GNUNET_CONFIGURATION_have_value (env->cfg, 2560 if (GNUNET_CONFIGURATION_have_value (env->cfg,
2556 component_name, "USE_IPv4")) 2561 component_name, "USE_IPv4"))
2557 { 2562 {
@@ -2707,6 +2712,8 @@ LIBGNUNET_PLUGIN_TRANSPORT_INIT (void *cls)
2707 "transport-https"); 2712 "transport-https");
2708 GNUNET_free (key_file); 2713 GNUNET_free (key_file);
2709 GNUNET_free (cert_file); 2714 GNUNET_free (cert_file);
2715 GNUNET_free (component_name);
2716
2710 libgnunet_plugin_transport_http_done(api); 2717 libgnunet_plugin_transport_http_done(api);
2711 return NULL; 2718 return NULL;
2712 } 2719 }
@@ -2718,7 +2725,6 @@ LIBGNUNET_PLUGIN_TRANSPORT_INIT (void *cls)
2718 2725
2719 GNUNET_assert((plugin->key!=NULL) && (plugin->cert!=NULL)); 2726 GNUNET_assert((plugin->key!=NULL) && (plugin->cert!=NULL));
2720 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "TLS certificate loaded\n"); 2727 GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "TLS certificate loaded\n");
2721
2722#endif 2728#endif
2723 2729
2724 GNUNET_assert ((port > 0) && (port <= 65535)); 2730 GNUNET_assert ((port > 0) && (port <= 65535));
@@ -2816,8 +2822,8 @@ LIBGNUNET_PLUGIN_TRANSPORT_INIT (void *cls)
2816 if ((plugin->use_ipv6 == GNUNET_NO) && (plugin->use_ipv4 == GNUNET_NO)) 2822 if ((plugin->use_ipv6 == GNUNET_NO) && (plugin->use_ipv4 == GNUNET_NO))
2817 GNUNET_asprintf(&tmp,"with NO IP PROTOCOL enabled"); 2823 GNUNET_asprintf(&tmp,"with NO IP PROTOCOL enabled");
2818 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,"HTTP Server with %s could not be started on port %u! %s plugin failed!\n",tmp, port, PROTOCOL_PREFIX); 2824 GNUNET_log (GNUNET_ERROR_TYPE_ERROR,"HTTP Server with %s could not be started on port %u! %s plugin failed!\n",tmp, port, PROTOCOL_PREFIX);
2819 GNUNET_free(tmp); 2825 GNUNET_free (tmp);
2820 GNUNET_free(component_name); 2826 GNUNET_free (component_name);
2821 libgnunet_plugin_transport_http_done (api); 2827 libgnunet_plugin_transport_http_done (api);
2822 return NULL; 2828 return NULL;
2823 } 2829 }