Created attachment 170997 [details] patch Myltibyte should probably be Multibyte
I've submitted this upstream and they committed it. I'll do an (un)vis import.
A commit references this bug: Author: brooks Date: Wed Jun 8 18:21:27 UTC 2016 New revision: 301679 URL: https://svnweb.freebsd.org/changeset/base/301679 Log: Update to a June 8th snapshot of (un)vis form NetBSD. This adds stravis() and some new encoding flags VIS_SHELL, VIS_META, and VIS_NOLOCALE. Assorted cleanups and fixes includeing a manpage typo[0]. PR: 210013 [0] Submitted by: pi [0] Changes: _U head/contrib/libc-vis/ head/contrib/libc-vis/unvis.c head/contrib/libc-vis/vis.3 head/contrib/libc-vis/vis.c head/contrib/libc-vis/vis.h head/lib/libc/gen/Symbol.map
I committed this a while ago. Apparently I'm too accustom to phabricator's auto-close function...
A commit references this bug: Author: brooks Date: Tue Nov 28 17:20:54 UTC 2017 New revision: 326324 URL: https://svnweb.freebsd.org/changeset/base/326324 Log: MFC r301679 (partial), r309626, r326307 r301679: Update to a June 8th snapshot of (un)vis form NetBSD. This adds stravis() and some new encoding flags VIS_SHELL, VIS_META, and VIS_NOLOCALE. Assorted cleanups and fixes includeing a manpage typo[0]. NOTE: The symbol for stravis() is not exported in this merge. r309626: strvis(3): Avoid internal state of multibyte functions being tainted. The mbtoc(3) and wctomb(3) functions use internal state which may be tainted before the call to strvis(3). In this context we can just use the thread-safe versions mbrtoc(3) and wcrtomb(3) which allow passing our own state from our stack. r326307: Update vis(3) the latest from NetBSD. This adds VIS_DQ for compatiblity with OpenBSD. Correct by an off-by-one error and a read buffer overflow detected using asan. PR: 210013 [0] Submitted by: pi [0] Changes: _U stable/10/ stable/10/contrib/libc-vis/unvis.3 stable/10/contrib/libc-vis/unvis.c stable/10/contrib/libc-vis/vis.3 stable/10/contrib/libc-vis/vis.c stable/10/contrib/libc-vis/vis.h