CVSROOT: /cvs Module name: src Changes by: [email protected] 2019/03/12 05:59:24
Modified files:
usr.bin/less : line.c
Log message:
Clean up UTF-8 handling in backc():
Use wchar_t instead of LWCHAR and mbtowc(3) instead of step_char().
Play it safe and handle all error cases, even in the arguably unlikely
case that linebuf[] contains UTF-8 encoding errors.
Reset mbtowc(3) internal state after failure for portability,
also in one place where mbtowc(3) was already introduced earlier.
OK nicm@
