Tcl_NumUtfChars counts wrong at end of malformed string
Closed / Fixedb2816a3afe4b11f5644b75e6daff28199031ec95Created 7 years agoUpdated 7 years ago
Descriptionplain2020-05-07 18:55:49
==== utf-4.13 Tcl_NumUtfChars: end of string FAILED
==== Contents of test case:
testnumutfchars foobar[testbytestring \xF2\xC2\xA0] end
---- Result was:
9
---- Result should have been (exact matching):
8
==== utf-4.13 FAILED
The algorithm in Tcl_NumUtfChars can go wrong only when TCL _UTF_MAX > 3
so that there is room to make certain troubles possible.
Referenced by2
683444cef2[b2816a3afe] Fix counting of malformed sequences at end of string. check-in2020-05-07 19:12:361c633ff6d0Test demonstrating bug in ticket [b2816a3afe]. check-in2020-05-07 18:56:37
dgpplain2020-05-07 19:09:47
Fix checked in. Merging to follow.
Log in (anonymous is fine) to add a comment.