diff options
author | LRN <lrn1986@gmail.com> | 2013-12-19 06:00:23 +0000 |
---|---|---|
committer | LRN <lrn1986@gmail.com> | 2013-12-19 06:00:23 +0000 |
commit | e0ca7357cd0bfedc5c29cb731b56279fef8da059 (patch) | |
tree | ecfd47cf59bc00e656b53fd59c58f5038e342d65 /src/transport/plugin_transport_http_common.c | |
parent | 92fd84dc7ef98452f848a62677c61a2b80b5835e (diff) | |
download | gnunet-e0ca7357cd0bfedc5c29cb731b56279fef8da059.tar.gz gnunet-e0ca7357cd0bfedc5c29cb731b56279fef8da059.zip |
malloc -> new
Diffstat (limited to 'src/transport/plugin_transport_http_common.c')
-rw-r--r-- | src/transport/plugin_transport_http_common.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/transport/plugin_transport_http_common.c b/src/transport/plugin_transport_http_common.c index de4cb9a26..c020118ac 100644 --- a/src/transport/plugin_transport_http_common.c +++ b/src/transport/plugin_transport_http_common.c | |||
@@ -60,7 +60,7 @@ http_split_address (const char * addr) | |||
60 | char *port_start = NULL; | 60 | char *port_start = NULL; |
61 | char *path_start = NULL; | 61 | char *path_start = NULL; |
62 | protocol_start = src; | 62 | protocol_start = src; |
63 | sp = GNUNET_malloc (sizeof (struct SplittedHTTPAddress)); | 63 | sp = GNUNET_new (struct SplittedHTTPAddress); |
64 | 64 | ||
65 | /* Address string consists of protocol://host[:port]path*/ | 65 | /* Address string consists of protocol://host[:port]path*/ |
66 | 66 | ||
@@ -455,7 +455,7 @@ http_common_socket_from_address (const void *addr, size_t addrlen, int *res) | |||
455 | return NULL; | 455 | return NULL; |
456 | } | 456 | } |
457 | 457 | ||
458 | s = GNUNET_malloc (sizeof (struct sockaddr_storage)); | 458 | s = GNUNET_new (struct sockaddr_storage); |
459 | GNUNET_asprintf (&to_conv, "%s:%u", spa->host, spa->port); | 459 | GNUNET_asprintf (&to_conv, "%s:%u", spa->host, spa->port); |
460 | if (GNUNET_SYSERR == GNUNET_STRINGS_to_address_ip (to_conv, strlen(to_conv), s)) | 460 | if (GNUNET_SYSERR == GNUNET_STRINGS_to_address_ip (to_conv, strlen(to_conv), s)) |
461 | { | 461 | { |