Up to [cvsweb.bsd.lv] / mandoc
Request diff between arbitrary revisions
Default branch: MAIN
Current tag: HEAD
Revision 1.274 / (download) - annotate - [select for diffs], Tue May 14 21:19:12 2024 UTC (4 months, 1 week ago) by schwarze
Branch: MAIN
CVS Tags: HEAD
Changes since 1.273: +12 -26 lines
Diff to previous 1.273 (unified)
Garbage collect dead code intended to write five- and six-byte UTF-8 sequences since the Unicode standard has been explicitly prohibiting the use of such sequences when encoding Unicode characters for more than 20 years now. While here, also weed out UTF-16 surrogates and codepoints in the invalid range 110000 to 1FFFFF if any are encountered. I hoped to write "no functional change", but to my shame it turns out there are unrelated bugs with \[uXXXX] parsing in roff_escape.c, so this new anti-surrogate check is actually reachable until those other bugs get fixed, and even after fixing those other bugs, it will remain useful as a defense in depth.