From a84dd1c15acbd9728ea35bd9f18178373236b92b Mon Sep 17 00:00:00 2001 From: Amitay Isaacs Date: Mon, 11 Sep 2017 15:59:19 +1000 Subject: [PATCH] ctdb-daemon: Free up record data if a call request is deferred BUG: https://bugzilla.samba.org/show_bug.cgi?id=13029 If a call request for a key (migration request) is in flight, then all the subsequent call requests for the same key are deferred. In that case, the data corresponding to key read from the local tdb is useless and there is no need to keep it around. Once the deferred call is reprocessed, the data corresponding to that key will be fetched again. Signed-off-by: Amitay Isaacs Reviewed-by: Martin Schwenke (cherry picked from commit 77c17b03cfc4734142fd86ba3cdd9663e75f34e3) --- ctdb/server/ctdb_daemon.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ctdb/server/ctdb_daemon.c b/ctdb/server/ctdb_daemon.c index 7f088f037e8..90f0e546831 100644 --- a/ctdb/server/ctdb_daemon.c +++ b/ctdb/server/ctdb_daemon.c @@ -676,6 +676,7 @@ static void daemon_request_call_from_client(struct ctdb_client *client, DEBUG(DEBUG_ERR,(__location__ " ctdb_ltdb_unlock() failed with error %d\n", ret)); } CTDB_DECREMENT_STAT(ctdb, pending_calls); + talloc_free(data.dptr); return; } } -- 2.13.5