commit 3eb4964af3ff6bfb34cea63e8a5265e76e964b3a
parent 2e31e44ffa614c5202edfe2abcc05a7880902640
Author: Hiltjo Posthuma <hiltjo@codemadness.org>
Date: Sun, 21 Jan 2018 21:14:39 +0100
Remove invalid leftover variable in uistatus()
Diffstat:
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/ui_ti.c b/ui_ti.c
@@ -143,7 +143,7 @@ uistatus(char *fmt, ...)
putp(tparm(enter_standout_mode));
va_start(ap, fmt);
- n = vsnprintf(bufout + n, sizeof(bufout) - n, fmt, ap);
+ n = vsnprintf(bufout, sizeof(bufout), fmt, ap);
va_end(ap);
if (n < sizeof(bufout)-1) {
diff --git a/ui_txt.c b/ui_txt.c
@@ -193,7 +193,7 @@ printuri(Item *item, size_t i)
item->host, item->type, item->selector, item->port);
break;
}
-
+
if (n >= sizeof(bufout))
bufout[sizeof(bufout)-1] = '\0';