diff options
Diffstat (limited to 'cli')
-rw-r--r-- | cli/src/cli-cmd-volume.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/cli/src/cli-cmd-volume.c b/cli/src/cli-cmd-volume.c index 70a7a1a19d7..b9fd56362cf 100644 --- a/cli/src/cli-cmd-volume.c +++ b/cli/src/cli-cmd-volume.c @@ -2102,14 +2102,14 @@ out: cli_cmd_sent_status_get (&sent); if ((sent == 0) && (parse_error == 0)) cli_out ("Volume remove-brick failed"); - } else { + } #if (USE_EVENTS) - if (!event_ret) { - gf_event (event, "%s", event_str); - GF_FREE (event_str); - } + if (!ret && !event_ret) + gf_event (event, "%s", event_str); + if (event_str) + GF_FREE (event_str); + #endif - } CLI_STACK_DESTROY (frame); |