[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r31203 - gnunet/src/transport
From: |
gnunet |
Subject: |
[GNUnet-SVN] r31203 - gnunet/src/transport |
Date: |
Mon, 9 Dec 2013 00:52:42 +0100 |
Author: grothoff
Date: 2013-12-09 00:52:42 +0100 (Mon, 09 Dec 2013)
New Revision: 31203
Modified:
gnunet/src/transport/plugin_transport_http.c
gnunet/src/transport/plugin_transport_http_server.c
Log:
-assert MHD_VERSION is always above 09E00, remove dead struct
Modified: gnunet/src/transport/plugin_transport_http.c
===================================================================
--- gnunet/src/transport/plugin_transport_http.c 2013-12-08 23:47:46 UTC
(rev 31202)
+++ gnunet/src/transport/plugin_transport_http.c 2013-12-08 23:52:42 UTC
(rev 31203)
@@ -52,37 +52,7 @@
struct HttpAddress *addr;
};
-/**
- * Context for address to string conversion.
- */
-struct PrettyPrinterContext
-{
- /**
- * Function to call with the result.
- */
- GNUNET_TRANSPORT_AddressStringCallback asc;
- /**
- * Plugin
- */
- struct Plugin *plugin;
-
- /**
- * Clsoure for 'asc'.
- */
- void *asc_cls;
-
- /**
- * Port to add after the IP address.
- */
- uint16_t port;
-
- uint32_t addrlen;
-
- int numeric;
-};
-
-
/**
* Encapsulation of all of the state of the plugin.
*/
@@ -106,6 +76,7 @@
static void
stop_session_timeout (struct Session *s);
+
/**
* Convert the transports address to a nice, human-readable
* format.
@@ -118,7 +89,7 @@
* @param numeric should (IP) addresses be displayed in numeric form?
* @param timeout after how long should we give up?
* @param asc function to call on each string
- * @param asc_cls closure for asc
+ * @param asc_cls closure for @a asc
*/
static void
http_plugin_address_pretty_printer (void *cls, const char *type,
@@ -128,9 +99,9 @@
GNUNET_TRANSPORT_AddressStringCallback asc,
void *asc_cls)
{
+ const struct HttpAddress *haddr = addr;
+
GNUNET_assert (cls != NULL);
- struct HttpAddress *haddr = (struct HttpAddress *) addr;
-
if (addrlen < (sizeof (struct HttpAddress)))
{
/* invalid address */
Modified: gnunet/src/transport/plugin_transport_http_server.c
===================================================================
--- gnunet/src/transport/plugin_transport_http_server.c 2013-12-08 23:47:46 UTC
(rev 31202)
+++ gnunet/src/transport/plugin_transport_http_server.c 2013-12-08 23:52:42 UTC
(rev 31203)
@@ -1177,7 +1177,6 @@
plugin->env->session_start (NULL, &s->target, PLUGIN_NAME, NULL, 0 ,s,
NULL, 0);
}
-#if MHD_VERSION >= 0x00090E00
if ((NULL == s->server_recv) || (NULL == s->server_send))
{
to = (HTTP_SERVER_NOT_VALIDATED_TIMEOUT.rel_value_us / 1000LL / 1000LL);
@@ -1196,7 +1195,6 @@
GNUNET_log_from (GNUNET_ERROR_TYPE_DEBUG, plugin->name,
"Setting timeout for %p to %u sec.\n", sc, to);
-#endif
return sc;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r31203 - gnunet/src/transport,
gnunet <=