From: Ruben Kerkhof Date: Sat, 5 Dec 2015 11:09:00 +0000 (+0100) Subject: libcollectdclient: free result of getaddrinfo X-Git-Tag: collectd-5.5.1~25^2~8 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=5b392ea020897afbc546274e6a6c64802ccfe546;p=collectd.git libcollectdclient: free result of getaddrinfo CID #37997 Signed-off-by: Florian Forster --- diff --git a/src/libcollectdclient/client.c b/src/libcollectdclient/client.c index 5db98e58..802e6439 100644 --- a/src/libcollectdclient/client.c +++ b/src/libcollectdclient/client.c @@ -526,9 +526,11 @@ static int lcc_open_netsocket (lcc_connection_t *c, /* {{{ */ if (status != 0) { lcc_set_errno (c, status); + freeaddrinfo (ai_res); return (-1); } + freeaddrinfo (ai_res); return (0); } /* }}} int lcc_open_netsocket */