---
st.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/st.c b/st.c
index caacf0c..112864e 100644
--- a/st.c
+++ b/st.c
@@ -2284,14 +2284,12 @@ void
tputc(Rune u)
{
char c[UTF_SIZ];
- int control;
- int width, len;
+ int control = ISCONTROL(u);;
+ int width = 1, len = 1;
Glyph *gp;
- control = ISCONTROL(u);
if (!IS_SET(MODE_UTF8) && !IS_SET(MODE_SIXEL)) {
c[0] = u;
- width = len = 1;
} else {
len = utf8encode(u, c);
if (!control && (width = wcwidth(u)) == -1) {
--
2.20.1- [hackers] [st][PATCH 00/24] odg patches - fix warnings/... Oliver Galvin
- [hackers] [st][PATCH 01/24] add gitignore Oliver Galvin
- [hackers] [st][PATCH 06/24] fix warnings from -Wim... Oliver Galvin
- [hackers] [st][PATCH 07/24] fix warning from -Wmay... Oliver Galvin
- [hackers] [st][PATCH 02/24] avoid unnecessarily ch... Oliver Galvin
- [hackers] [st][PATCH 03/24] Reduce variable scope ... Oliver Galvin
- Re: [hackers] [st][PATCH 03/24] Reduce variabl... David Phillips
- [hackers] [st][PATCH 22/24] fix memory leak - dest... Oliver Galvin
- [hackers] [st][PATCH 19/24] improve type and const... Oliver Galvin
- [hackers] [st][PATCH 21/24] avoid unnecessarily li... Oliver Galvin
- Re: [hackers] [st][PATCH 21/24] avoid unnecess... Stephen Gregoratto
- [hackers] [st][PATCH 14/24] now st can build witho... Oliver Galvin
- Re: [hackers] [st][PATCH 14/24] now st can bui... Quentin Rameau
- [hackers] [st][PATCH 05/24] avoid warnings from -W... Oliver Galvin
