From e0ca7357cd0bfedc5c29cb731b56279fef8da059 Mon Sep 17 00:00:00 2001 From: LRN Date: Thu, 19 Dec 2013 06:00:23 +0000 Subject: malloc -> new --- src/transport/plugin_transport_http_common.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/transport/plugin_transport_http_common.c') 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) char *port_start = NULL; char *path_start = NULL; protocol_start = src; - sp = GNUNET_malloc (sizeof (struct SplittedHTTPAddress)); + sp = GNUNET_new (struct SplittedHTTPAddress); /* Address string consists of protocol://host[:port]path*/ @@ -455,7 +455,7 @@ http_common_socket_from_address (const void *addr, size_t addrlen, int *res) return NULL; } - s = GNUNET_malloc (sizeof (struct sockaddr_storage)); + s = GNUNET_new (struct sockaddr_storage); GNUNET_asprintf (&to_conv, "%s:%u", spa->host, spa->port); if (GNUNET_SYSERR == GNUNET_STRINGS_to_address_ip (to_conv, strlen(to_conv), s)) { -- cgit v1.2.3