about summary refs log tree commit diff
path: root/Src/utils.c
diff options
context:
space:
mode:
Diffstat (limited to 'Src/utils.c')
-rw-r--r--Src/utils.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/Src/utils.c b/Src/utils.c
index d30dacca8..e7a4595b8 100644
--- a/Src/utils.c
+++ b/Src/utils.c
@@ -1225,7 +1225,10 @@ preprompt(void)
 	str = promptexpand(eolmark, 1, NULL, NULL, NULL);
 	countprompt(str, &w, 0, -1);
 	opts[PROMPTPERCENT] = percents;
-	fprintf(shout, "%s%*s\r", str, (int)columns - w - !hasxn, "");
+	zputs(str, shout);
+	for (w = (int)columns - w - !hasxn; w > 0; w--)
+	    putc(' ', shout);
+	putc('\r', shout);
 	free(str);
     }