NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: lib/55118: Recent change in terminal output breaks anita



It does:
Shall<reset-attrs><cursor right><foreground-white><background-blue>we<reset-attrs><cursor-right><foreground-white><background-blue>continue?

I *think* this is because the xterm-color (if I am guessing right) now clamps color pair entries instead of truncating them.

Can you try:
1. using a terminal that does not support color.
2. applying this patch

Index: term_private.h
===================================================================
RCS file: /cvsroot/src/lib/libterminfo/term_private.h,v
retrieving revision 1.14
diff -u -p -u -r1.14 term_private.h
--- term_private.h      27 Mar 2020 17:39:53 -0000      1.14
+++ term_private.h      28 Mar 2020 15:11:58 -0000
@@ -273,8 +273,7 @@ static __inline void
 _ti_encode_buf_num(TBUF *tbuf, size_t num, int rtype)
 {
        if (rtype == TERMINFO_RTYPE_O1) {
-               if (num > SHRT_MAX)
-                       num = SHRT_MAX;
+               num &= 0xffff;
                _ti_encode_buf_16(tbuf, num);
        } else {
                _ti_encode_buf_32(tbuf, num);


christos

Attachment: signature.asc
Description: Message signed with OpenPGP



Home | Main Index | Thread Index | Old Index