diff options
author | Sander Vrijders <[email protected]> | 2017-02-04 09:12:47 +0000 |
---|---|---|
committer | Sander Vrijders <[email protected]> | 2017-02-04 09:12:47 +0000 |
commit | e3b1288354349edc53c7c3c9ebd3efe23a7df10d (patch) | |
tree | 3a47f2b2db895173a1e3605df3fbdc925b7b127b /src/ipcpd/ipcp.c | |
parent | c677d8a88065e6bc8e071f3f03a440e4ed083abb (diff) | |
parent | a30e244407655d16429ef442ac23db43a548bf95 (diff) | |
download | ouroboros-e3b1288354349edc53c7c3c9ebd3efe23a7df10d.tar.gz ouroboros-e3b1288354349edc53c7c3c9ebd3efe23a7df10d.zip |
Merged in dstaesse/ouroboros/be-wip (pull request #359)
irmd: Fix memleak in registry
Diffstat (limited to 'src/ipcpd/ipcp.c')
-rw-r--r-- | src/ipcpd/ipcp.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/ipcpd/ipcp.c b/src/ipcpd/ipcp.c index 2c3beed7..2115f7c1 100644 --- a/src/ipcpd/ipcp.c +++ b/src/ipcpd/ipcp.c @@ -49,8 +49,6 @@ static void * ipcp_main_loop(void * o) dif_config_msg_t * conf_msg; struct dif_config conf; - char * msg_name_dup; - struct timeval ltv = {(SOCKET_TIMEOUT / 1000), (SOCKET_TIMEOUT % 1000) * 1000}; @@ -154,12 +152,9 @@ static void * ipcp_main_loop(void * o) LOG_ERR("Ap_reg unsupported."); break; } - msg_name_dup = strdup(msg->name); ret_msg.has_result = true; ret_msg.result = - ipcpi.ops->ipcp_name_reg(msg_name_dup); - if (ret_msg.result < 0) - free(msg_name_dup); + ipcpi.ops->ipcp_name_reg(msg->name); break; case IPCP_MSG_CODE__IPCP_NAME_UNREG: if (ipcpi.ops->ipcp_name_unreg == NULL) { |