summaryrefslogtreecommitdiffstats
path: root/cli/src/cli3_1-cops.c
diff options
context:
space:
mode:
Diffstat (limited to 'cli/src/cli3_1-cops.c')
-rw-r--r--cli/src/cli3_1-cops.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/cli/src/cli3_1-cops.c b/cli/src/cli3_1-cops.c
index 064845087b8..a88d0c6957f 100644
--- a/cli/src/cli3_1-cops.c
+++ b/cli/src/cli3_1-cops.c
@@ -611,9 +611,14 @@ gf_cli3_1_defrag_volume_cbk (struct rpc_req *req, struct iovec *iov,
if (rsp.op_errno == 4)
status = "failed";
- cli_out ("rebalance %s: rebalanced %"PRId64" files of size %"PRId64
- " (total files scanned %"PRId64")", status,
- rsp.files, rsp.size, rsp.lookedup_files);
+ if (rsp.files) {
+ cli_out ("rebalance %s: rebalanced %"PRId64
+ " files of size %"PRId64" (total files"
+ " scanned %"PRId64")", status,
+ rsp.files, rsp.size, rsp.lookedup_files);
+ } else {
+ cli_out ("rebalance %s", status);
+ }
}
}