summaryrefslogtreecommitdiffstats
path: root/cli
diff options
context:
space:
mode:
Diffstat (limited to 'cli')
-rw-r--r--cli/src/cli-rpc-ops.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/cli/src/cli-rpc-ops.c b/cli/src/cli-rpc-ops.c
index 6288b01a6af..da9df4cc05e 100644
--- a/cli/src/cli-rpc-ops.c
+++ b/cli/src/cli-rpc-ops.c
@@ -10849,9 +10849,12 @@ gf_cli_print_bitrot_scrub_status (dict_t *dict)
cli_out ("%s: %"PRIu64 "\n", "Number of Unsigned files",
unsigned_files);
- cli_out ("%s: %s\n", "Last completed scrub time",
- (*last_scrub) ? last_scrub : "Scrubber pending to "
- "complete.");
+ if ((!last_scrub) || !strcmp (last_scrub, ""))
+ cli_out ("%s: %s\n", "Last completed scrub time",
+ "Scrubber pending to complete.");
+ else
+ cli_out ("%s: %s\n", "Last completed scrub time",
+ last_scrub);
/* Printing last scrub duration time in human readable form*/
days = scrub_time/86400;