aboutsummaryrefslogtreecommitdiffstats
path: root/hicn-light/src/hicn/io/hicnListener.c
diff options
context:
space:
mode:
Diffstat (limited to 'hicn-light/src/hicn/io/hicnListener.c')
-rw-r--r--hicn-light/src/hicn/io/hicnListener.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/hicn-light/src/hicn/io/hicnListener.c b/hicn-light/src/hicn/io/hicnListener.c
index bc49f4cee..8647a4d54 100644
--- a/hicn-light/src/hicn/io/hicnListener.c
+++ b/hicn-light/src/hicn/io/hicnListener.c
@@ -216,7 +216,10 @@ static void _hicnListener_readcb(int fd, PARCEventType what, void *listener_void
static bool _isEmptyAddressIPv4(Address *address) {
bool res = false;
- if (strcmp("inet4://0.0.0.0:1234", addressToString(address)) == 0) res = true;
+ char * str = addressToString(address);
+ if (strcmp("inet4://0.0.0.0:1234", str) == 0) res = true;
+ parcMemory_Deallocate((void**)&str);
+
return res;
}
@@ -228,6 +231,7 @@ ListenerOps *hicnListener_CreateInet(Forwarder *forwarder, char *symbolic,
hicn->forwarder = forwarder;
hicn->listenerName = parcMemory_StringDuplicate(symbolic, strlen(symbolic));
+ hicn->logger = logger_Acquire(forwarder_GetLogger(forwarder));
hicn->conn_id = forwarder_GetNextConnectionId(forwarder);
hicn->inetFamily = IPv4;