From 611c9a0ba9472aae17a3099da20ea2d836cef84a Mon Sep 17 00:00:00 2001 From: Swen Schillig Date: Tue, 13 Mar 2018 09:42:24 +0100 Subject: [PATCH] ctdb: Fixing memory leak in ctdb_tcp_tnode_cb It is expected by the caller(queue_process) that the callback is free'ing the memory referenced by the data pointer. Signed-off-by: Swen Schillig Reviewed-by: Martin Schwenke Reviewed-by: Jeremy Allison --- ctdb/tcp/tcp_connect.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ctdb/tcp/tcp_connect.c b/ctdb/tcp/tcp_connect.c index 17aafc415f7c..13452a5e83b6 100644 --- a/ctdb/tcp/tcp_connect.c +++ b/ctdb/tcp/tcp_connect.c @@ -75,6 +75,7 @@ void ctdb_tcp_tnode_cb(uint8_t *data, size_t cnt, void *private_data) tnode->connect_te = tevent_add_timer(node->ctdb->ev, tnode, timeval_current_ofs(3, 0), ctdb_tcp_node_connect, node); + TALLOC_FREE(data); } /* -- 2.34.1