diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2010-07-12 15:18:26 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2010-07-12 15:18:26 +0000 |
commit | eb394c314af6cd85e99aed3badea356776a55c71 (patch) | |
tree | 3f324018fe370a6d2b99f31a55801ee871c7a615 | |
parent | ee63bbc447f98b4a65df6a728d04aac0118e2437 (diff) | |
download | gnunet-eb394c314af6cd85e99aed3badea356776a55c71.tar.gz gnunet-eb394c314af6cd85e99aed3badea356776a55c71.zip |
-rw-r--r-- | src/transport/plugin_transport_http.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/transport/plugin_transport_http.c b/src/transport/plugin_transport_http.c index 882437400..9944791d7 100644 --- a/src/transport/plugin_transport_http.c +++ b/src/transport/plugin_transport_http.c | |||
@@ -2145,6 +2145,7 @@ libgnunet_plugin_transport_http_init (void *cls) | |||
2145 | GNUNET_assert ((port > 0) && (port <= 65535)); | 2145 | GNUNET_assert ((port > 0) && (port <= 65535)); |
2146 | plugin->port_inbound = port; | 2146 | plugin->port_inbound = port; |
2147 | gn_timeout = GNUNET_CONSTANTS_IDLE_CONNECTION_TIMEOUT; | 2147 | gn_timeout = GNUNET_CONSTANTS_IDLE_CONNECTION_TIMEOUT; |
2148 | unsigned int timeout = (gn_timeout.value) / 1000; | ||
2148 | if ((plugin->http_server_daemon_v4 == NULL) && (plugin->http_server_daemon_v6 == NULL) && (port != 0)) | 2149 | if ((plugin->http_server_daemon_v4 == NULL) && (plugin->http_server_daemon_v6 == NULL) && (port != 0)) |
2149 | { | 2150 | { |
2150 | plugin->http_server_daemon_v6 = MHD_start_daemon (MHD_USE_IPv6 | MHD_USE_DEBUG, | 2151 | plugin->http_server_daemon_v6 = MHD_start_daemon (MHD_USE_IPv6 | MHD_USE_DEBUG, |
@@ -2153,7 +2154,7 @@ libgnunet_plugin_transport_http_init (void *cls) | |||
2153 | plugin , &mdh_access_cb, plugin, | 2154 | plugin , &mdh_access_cb, plugin, |
2154 | MHD_OPTION_CONNECTION_LIMIT, (unsigned int) 16, | 2155 | MHD_OPTION_CONNECTION_LIMIT, (unsigned int) 16, |
2155 | MHD_OPTION_PER_IP_CONNECTION_LIMIT, (unsigned int) 1, | 2156 | MHD_OPTION_PER_IP_CONNECTION_LIMIT, (unsigned int) 1, |
2156 | MHD_OPTION_CONNECTION_TIMEOUT, (gn_timeout.value / 1000), | 2157 | MHD_OPTION_CONNECTION_TIMEOUT, (unsigned int) timeout, |
2157 | MHD_OPTION_CONNECTION_MEMORY_LIMIT, (size_t) (16 * 1024), | 2158 | MHD_OPTION_CONNECTION_MEMORY_LIMIT, (size_t) (16 * 1024), |
2158 | MHD_OPTION_NOTIFY_COMPLETED, &mhd_termination_cb, NULL, | 2159 | MHD_OPTION_NOTIFY_COMPLETED, &mhd_termination_cb, NULL, |
2159 | MHD_OPTION_END); | 2160 | MHD_OPTION_END); |
@@ -2163,7 +2164,7 @@ libgnunet_plugin_transport_http_init (void *cls) | |||
2163 | plugin , &mdh_access_cb, plugin, | 2164 | plugin , &mdh_access_cb, plugin, |
2164 | MHD_OPTION_CONNECTION_LIMIT, (unsigned int) 16, | 2165 | MHD_OPTION_CONNECTION_LIMIT, (unsigned int) 16, |
2165 | MHD_OPTION_PER_IP_CONNECTION_LIMIT, (unsigned int) 1, | 2166 | MHD_OPTION_PER_IP_CONNECTION_LIMIT, (unsigned int) 1, |
2166 | MHD_OPTION_CONNECTION_TIMEOUT, (gn_timeout.value / 1000), | 2167 | MHD_OPTION_CONNECTION_TIMEOUT, (unsigned int) timeout, |
2167 | MHD_OPTION_CONNECTION_MEMORY_LIMIT, (size_t) (16 * 1024), | 2168 | MHD_OPTION_CONNECTION_MEMORY_LIMIT, (size_t) (16 * 1024), |
2168 | MHD_OPTION_NOTIFY_COMPLETED, &mhd_termination_cb, NULL, | 2169 | MHD_OPTION_NOTIFY_COMPLETED, &mhd_termination_cb, NULL, |
2169 | MHD_OPTION_END); | 2170 | MHD_OPTION_END); |