=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/less/cmdbuf.c,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- src/usr.bin/less/cmdbuf.c 2016/09/17 15:06:41 1.16 +++ src/usr.bin/less/cmdbuf.c 2019/05/15 18:06:09 1.17 @@ -117,29 +117,16 @@ } /* - * Display a string, usually as a prompt for input into the command buffer. + * Display an ASCII string, usually as a prompt for input, + * into the command buffer. */ void cmd_putstr(char *s) { - LWCHAR prev_ch = 0; - LWCHAR ch; - char *endline = s + strlen(s); while (*s != '\0') { - char *ns = s; - ch = step_char(&ns, +1, endline); - while (s < ns) - putchr(*s++); - if (!utf_mode) { - cmd_col++; - prompt_col++; - } else if (!is_composing_char(ch) && - !is_combining_char(prev_ch, ch)) { - int width = is_wide_char(ch) ? 2 : 1; - cmd_col += width; - prompt_col += width; - } - prev_ch = ch; + putchr(*s++); + cmd_col++; + prompt_col++; } }