summaryrefslogtreecommitdiff
path: root/src/lib/irm.c
diff options
context:
space:
mode:
authordimitri staessens <[email protected]>2016-12-27 23:30:06 +0100
committerdimitri staessens <[email protected]>2016-12-27 23:30:06 +0100
commit6166259f74855fe9e6976175eeb7b16912bc477a (patch)
treedfac787e5565e576dbc0f96c2715a469e4fd3c20 /src/lib/irm.c
parentdbd901e65371ae390c36e7f6ed4a8bf59db6a5f6 (diff)
downloadouroboros-6166259f74855fe9e6976175eeb7b16912bc477a.tar.gz
ouroboros-6166259f74855fe9e6976175eeb7b16912bc477a.zip
lib: Fix memleak in irm.c
Diffstat (limited to 'src/lib/irm.c')
-rw-r--r--src/lib/irm.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/irm.c b/src/lib/irm.c
index 4b9a6285..0d9d0f86 100644
--- a/src/lib/irm.c
+++ b/src/lib/irm.c
@@ -358,6 +358,9 @@ int irm_bind_ap(char * ap,
msg.opts = opts;
recv_msg = send_recv_irm_msg(&msg);
+
+ free(full_ap_name);
+
if (recv_msg == NULL)
return -1;
@@ -369,7 +372,6 @@ int irm_bind_ap(char * ap,
ret = recv_msg->result;
irm_msg__free_unpacked(recv_msg, NULL);
- free(full_ap_name);
return ret;
}