From e41e2feba0a92121ff975a62d42dfaa8998f11d5 Mon Sep 17 00:00:00 2001 From: Martin Schwenke Date: Thu, 15 Aug 2019 15:45:16 +1000 Subject: ctdb-tcp: Use TALLOC_FREE() BUG: https://bugzilla.samba.org/show_bug.cgi?id=14084 Signed-off-by: Martin Schwenke Reviewed-by: Amitay Isaacs (cherry picked from commit d80d9edb4dc107b15a35a39e5c966a3eaed6453a) --- ctdb/tcp/tcp_connect.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'ctdb') diff --git a/ctdb/tcp/tcp_connect.c b/ctdb/tcp/tcp_connect.c index 1f2379cdb79..f2d036fb5f7 100644 --- a/ctdb/tcp/tcp_connect.c +++ b/ctdb/tcp/tcp_connect.c @@ -46,10 +46,8 @@ void ctdb_tcp_stop_connection(struct ctdb_node *node) node->private_data, struct ctdb_tcp_node); ctdb_queue_set_fd(tnode->out_queue, -1); - talloc_free(tnode->connect_te); - talloc_free(tnode->connect_fde); - tnode->connect_fde = NULL; - tnode->connect_te = NULL; + TALLOC_FREE(tnode->connect_te); + TALLOC_FREE(tnode->connect_fde); if (tnode->out_fd != -1) { close(tnode->out_fd); tnode->out_fd = -1; -- cgit v1.2.1