summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/ccan/tally/tally.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ccan/tally/tally.c b/lib/ccan/tally/tally.c
index 774373ca0f..29f0555880 100644
--- a/lib/ccan/tally/tally.c
+++ b/lib/ccan/tally/tally.c
@@ -506,11 +506,11 @@ char *tally_histogram(const struct tally *tally,
if (count > covered) {
count -= covered;
+ memset(p, '*', count);
} else {
count = 0;
}
- memset(p, '*', count);
p += count;
*p = '\n';
p++;