X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=st.c;h=b66791a2745319450dfcb604946cc2ff6a3a1c75;hb=f9dc374ea01c2921ec3bd1214f292a7036d069ae;hp=aba034f84fd6785ce40f8cb9746976f372e9796b;hpb=fa19f241a34deddf6e089ab462cbd9cb02f61b3d;p=st.git diff --git a/st.c b/st.c index aba034f..b66791a 100644 --- a/st.c +++ b/st.c @@ -2308,9 +2308,9 @@ techo(char *buf, int len) { for(; len > 0; buf++, len--) { char c = *buf; - if(c < '\x20') { /* control code */ + if(c < 0x20 || c == 0177) { /* control code */ if(c != '\n' && c != '\r' && c != '\t') { - c |= '\x40'; + c ^= '\x40'; tputc("^", 1); } tputc(&c, 1);