aboutsummaryrefslogtreecommitdiff
path: root/src/transport/plugin_transport_http.c
diff options
context:
space:
mode:
authorMatthias Wachs <wachs@net.in.tum.de>2010-07-29 15:39:01 +0000
committerMatthias Wachs <wachs@net.in.tum.de>2010-07-29 15:39:01 +0000
commitfe89565ba923f9ef70b6715196bcbf8b34f5f260 (patch)
treedb66dbbc6fd7ec74860fb86c46395b13e52a7ae0 /src/transport/plugin_transport_http.c
parent336c2abe4e816bbace409e4503f87e38fb1cac40 (diff)
downloadgnunet-fe89565ba923f9ef70b6715196bcbf8b34f5f260.tar.gz
gnunet-fe89565ba923f9ef70b6715196bcbf8b34f5f260.zip
Diffstat (limited to 'src/transport/plugin_transport_http.c')
-rw-r--r--src/transport/plugin_transport_http.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/transport/plugin_transport_http.c b/src/transport/plugin_transport_http.c
index 99b6053cf..9893cd27c 100644
--- a/src/transport/plugin_transport_http.c
+++ b/src/transport/plugin_transport_http.c
@@ -48,6 +48,8 @@
48#define INBOUND GNUNET_NO 48#define INBOUND GNUNET_NO
49#define OUTBOUND GNUNET_YES 49#define OUTBOUND GNUNET_YES
50 50
51#define PROTOCOL_PREFIX "http"
52
51/** 53/**
52 * Text of the response sent back after the last bytes of a PUT 54 * Text of the response sent back after the last bytes of a PUT
53 * request have been received (just to formally obey the HTTP 55 * request have been received (just to formally obey the HTTP
@@ -418,7 +420,7 @@ static char * create_url(void * cls, const void * addr, size_t addrlen, size_t i
418 420
419 GNUNET_assert ((addr!=NULL) && (addrlen != 0)); 421 GNUNET_assert ((addr!=NULL) && (addrlen != 0));
420 GNUNET_asprintf(&url, 422 GNUNET_asprintf(&url,
421 "http://%s/%s;%u", 423 "%s://%s/%s;%u", PROTOCOL_PREFIX,
422 http_plugin_address_to_string(NULL, addr, addrlen), 424 http_plugin_address_to_string(NULL, addr, addrlen),
423 (char *) (&plugin->my_ascii_hash_ident),id); 425 (char *) (&plugin->my_ascii_hash_ident),id);
424 426
@@ -2116,7 +2118,7 @@ http_plugin_address_pretty_printer (void *cls,
2116 asc (asc_cls, NULL); 2118 asc (asc_cls, NULL);
2117 return; 2119 return;
2118 } 2120 }
2119 res = GNUNET_asprintf(&ret,"http://%s:%u/",address,port); 2121 res = GNUNET_asprintf(&ret,"%s://%s:%u/", PROTOCOL_PREFIX, address, port);
2120 GNUNET_free (address); 2122 GNUNET_free (address);
2121 GNUNET_assert(res != 0); 2123 GNUNET_assert(res != 0);
2122 asc (asc_cls, ret); 2124 asc (asc_cls, ret);