Module: kamailio
Branch: master
Commit: c5fa782d551197319972fddcac8d02c626143520
URL:
https://github.com/kamailio/kamailio/commit/c5fa782d551197319972fddcac8d02c…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: GitHub <noreply(a)github.com>
Date: 2016-11-02T15:49:52+01:00
Merge pull request #843 from kamailio/jannsonrpc-c-shm-memleak
janssonrpc-c: fix shared memory leak on notification requests
---
Modified: modules/janssonrpc-c/janssonrpc_io.c
---
Diff:
https://github.com/kamailio/kamailio/commit/c5fa782d551197319972fddcac8d02c…
Patch:
https://github.com/kamailio/kamailio/commit/c5fa782d551197319972fddcac8d02c…
---
diff --git a/modules/janssonrpc-c/janssonrpc_io.c b/modules/janssonrpc-c/janssonrpc_io.c
index 036032e..a25e40d 100644
--- a/modules/janssonrpc-c/janssonrpc_io.c
+++ b/modules/janssonrpc-c/janssonrpc_io.c
@@ -534,6 +534,8 @@ void cmd_pipe_cb(int fd, short event, void *arg)
WARN("%s could not be sent to connection group: %.*s\n",
type, STR(req_cmd->conn));
fail_request(JRPC_ERR_SEND, req, "Failed to send request");
+ } else if (req_cmd->notify_only == true) { // free notification requests if they are
sent
+ free_req_cmd(req_cmd);
}
end: