aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPřemysl Janouch <p.janouch@gmail.com>2016-01-04 00:58:57 +0100
committerPřemysl Janouch <p.janouch@gmail.com>2016-01-04 00:58:57 +0100
commitbc7e83137ed2a14957e1b3feb5de658f8505ed57 (patch)
treeac62e430509f2a1532b72982916a41c3410e656a
parent8c06ec3276ff10f8b970a83467e0b3c4e28f4f5f (diff)
downloadliberty-bc7e83137ed2a14957e1b3feb5de658f8505ed57.tar.gz
liberty-bc7e83137ed2a14957e1b3feb5de658f8505ed57.tar.xz
liberty-bc7e83137ed2a14957e1b3feb5de658f8505ed57.zip
Fix usage of freeaddrinfo() in connector
-rw-r--r--liberty.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/liberty.c b/liberty.c
index 78371f5..fece828 100644
--- a/liberty.c
+++ b/liberty.c
@@ -3953,10 +3953,11 @@ connector_target_destroy (struct connector_target *self)
async_cancel (self->getaddrinfo_event);
if (self->getaddrinfo_error)
error_free (self->getaddrinfo_error);
+ if (self->results)
+ freeaddrinfo (self->results);
free (self->hostname);
free (self->service);
- freeaddrinfo (self->results);
free (self);
}