From f2ce05561c29c48640b72d0e813dd93b0282bd5e Mon Sep 17 00:00:00 2001 From: Ravishankar N Date: Wed, 31 Aug 2016 10:47:45 +0530 Subject: cli: Fix double unref of dict Backport of http://review.gluster.org/#/c/15368/ Problem: `gluster system:: uuid get` hangs due to double unref of dict. Fix: Remove the unnecessary unref in cli_cmd_uuid_get_cbk(). In the said function, if calling proc->fn() is sucessful, the dict is automatically unrefed in its cbk as a part of cli_local_wipe(). If calling proc->fn() fails, then CLI_STACK_DESTROY() takes care of the unref. Change-Id: Ib656d200f14a27415b36794a0bdadfe36b0d5306 BUG: 1371912 Signed-off-by: Ravishankar N (cherry picked from commit 2d3292fd29884b16cac058f937f91cfda197eca6) Reviewed-on: http://review.gluster.org/15376 Smoke: Gluster Build System CentOS-regression: Gluster Build System NetBSD-regression: NetBSD Build System Reviewed-by: Atin Mukherjee --- cli/src/cli-cmd-system.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/cli/src/cli-cmd-system.c b/cli/src/cli-cmd-system.c index 89d7d23187e..ad6bb7387eb 100644 --- a/cli/src/cli-cmd-system.c +++ b/cli/src/cli-cmd-system.c @@ -319,9 +319,6 @@ out: cli_out ("uuid get failed"); } - if (dict) - dict_unref (dict); - CLI_STACK_DESTROY (frame); return ret; } -- cgit