From de237d4dc2cafee55bd50a15fbeb2d7a880a87cf Mon Sep 17 00:00:00 2001 From: Ralph Corderoy Date: Sat, 13 May 2017 18:39:06 +0100 Subject: [PATCH] uip/folder.c: Rewrite plural test to common form. The common form is a choice between "" and "s". This one occurrence was using " " and "s" so either output was a fixed width. Alter the printf(3) format string from `%s' to `%1s' to provide that instead. Allows the new code to be altered by an upcoming `plural' change. --- uip/folder.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/uip/folder.c b/uip/folder.c index 23aea0b7..68e9182d 100644 --- a/uip/folder.c +++ b/uip/folder.c @@ -568,9 +568,9 @@ print_folders (void) nummsgdigits, "no", fi[i].others ? lowmsgdigits + hghmsgdigits + 5 : 0, ""); } else { - printf ("has %*d message%s (%*d-%*d)", + printf ("has %*d message%1s (%*d-%*d)", nummsgdigits, fi[i].nummsg, - (fi[i].nummsg == 1) ? " " : "s", + (fi[i].nummsg == 1) ? "" : "s", lowmsgdigits, fi[i].lowmsg, hghmsgdigits, fi[i].hghmsg); if (fi[i].curmsg >= fi[i].lowmsg && fi[i].curmsg <= fi[i].hghmsg) { -- 2.56.0