From 434a4b0ca9418ec31eec243e5f77c1af8e67a070 Mon Sep 17 00:00:00 2001 From: Christian Grothoff Date: Wed, 28 Sep 2011 06:51:49 +0000 Subject: MHD has a better way than a configure test for this --- src/transport/plugin_transport_http_server.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'src/transport') diff --git a/src/transport/plugin_transport_http_server.c b/src/transport/plugin_transport_http_server.c index b97ab3306..8303263f6 100644 --- a/src/transport/plugin_transport_http_server.c +++ b/src/transport/plugin_transport_http_server.c @@ -512,8 +512,9 @@ found: GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name, "Server: Setting Timeout to %u\n", to); #endif -// MHD_set_connection_option (mhd_connection, MHD_CONNECTION_OPTION_TIMEOUT, to); - +#if MHD_VERSION >= 0x00090E00 + MHD_set_connection_option (mhd_connection, MHD_CONNECTION_OPTION_TIMEOUT, to); +#endif (*httpSessionCache) = sc; } @@ -636,7 +637,9 @@ server_disconnect_cb (void *cls, struct MHD_Connection *connection, { tc = s->server_recv; tc->disconnect = GNUNET_YES; -// MHD_set_connection_option (sc->mhd_conn, MHD_CONNECTION_OPTION_TIMEOUT, 1); +#if MHD_VERSION >= 0x00090E00 + MHD_set_connection_option (sc->mhd_conn, MHD_CONNECTION_OPTION_TIMEOUT, 1); +#endif } } if (sc->direction == _RECEIVE) @@ -651,7 +654,9 @@ server_disconnect_cb (void *cls, struct MHD_Connection *connection, { tc = s->server_send; tc->disconnect = GNUNET_YES; -// MHD_set_connection_option (sc->mhd_conn, MHD_CONNECTION_OPTION_TIMEOUT, 1); +#if MHD_VERSION >= 0x00090E00 + MHD_set_connection_option (sc->mhd_conn, MHD_CONNECTION_OPTION_TIMEOUT, 1); +#endif } if (s->msg_tk != NULL) { -- cgit v1.2.3