From 9708bd1f922ca38973cba65b4890c67c2edc6e2b Mon Sep 17 00:00:00 2001 From: Krutika Dhananjay Date: Mon, 22 Oct 2012 15:30:49 +0530 Subject: glusterd: do dict unref after sending reply to cli This patch channelizes dict unrefs of dictionaries created from the cli req during volume ops to one common function - glusterd_to_cli() - which is guaranteed to be called irrespective of whether the command succeeds or fails. This patch also removes extra unrefs at a few places. Change-Id: Ic8ba7166387b5dfd1f5ae860539e1b7093a94662 BUG: 861044 Signed-off-by: Krutika Dhananjay Reviewed-on: http://review.gluster.org/4003 Tested-by: Gluster Build System Reviewed-by: Amar Tumballi Reviewed-by: Anand Avati --- xlators/mgmt/glusterd/src/glusterd-log-ops.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'xlators/mgmt/glusterd/src/glusterd-log-ops.c') diff --git a/xlators/mgmt/glusterd/src/glusterd-log-ops.c b/xlators/mgmt/glusterd/src/glusterd-log-ops.c index fa576212a..c88065c07 100644 --- a/xlators/mgmt/glusterd/src/glusterd-log-ops.c +++ b/xlators/mgmt/glusterd/src/glusterd-log-ops.c @@ -88,8 +88,6 @@ out: snprintf (msg, sizeof (msg), "Operation failed"); ret = glusterd_op_send_cli_response (cli_op, ret, 0, req, dict, msg); - if (dict) - dict_unref (dict); } free (cli_req.dict.dict_val); -- cgit