diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-04-24 10:23:33 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-04-24 10:23:33 (GMT) |
commit | da116b95a31241dc3abb6eed7d8f8eb3a9487232 (patch) | |
tree | 3b98b64461c97646bdbd3e8235aad6b7bf1bb2c3 /generic/tclStringObj.c | |
parent | b48319b304980c06ca5dd093770f8234eb8dbec5 (diff) | |
parent | 2ca7ab9af0d59c9907dde3d844e1785d33df4812 (diff) | |
download | tcl-da116b95a31241dc3abb6eed7d8f8eb3a9487232.zip tcl-da116b95a31241dc3abb6eed7d8f8eb3a9487232.tar.gz tcl-da116b95a31241dc3abb6eed7d8f8eb3a9487232.tar.bz2 |
Merge 8.6. This mainly introduces the overlong check into Tcl_UtfPrev(). 10 testcase changed results, all of them due to the Tcl_UtfPrev() improvement. Tcl_UtfNext() is not affected: Previous implementation was based on Tcl_UtfToUniChar(), which already did this check.
Diffstat (limited to 'generic/tclStringObj.c')
-rw-r--r-- | generic/tclStringObj.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/generic/tclStringObj.c b/generic/tclStringObj.c index 2025674..78e49f9 100644 --- a/generic/tclStringObj.c +++ b/generic/tclStringObj.c @@ -1171,10 +1171,10 @@ Tcl_AppendLimitedToObj( } eLen = strlen(ellipsis); while (eLen > limit) { - eLen = Tcl_UtfPrev(ellipsis+eLen, ellipsis) - ellipsis; + eLen = TclUtfPrev(ellipsis+eLen, ellipsis) - ellipsis; } - toCopy = Tcl_UtfPrev(bytes+limit+1-eLen, bytes) - bytes; + toCopy = TclUtfPrev(bytes+limit+1-eLen, bytes) - bytes; } /* @@ -2614,7 +2614,7 @@ AppendPrintfToObjVA( * multi-byte characters. */ - q = Tcl_UtfPrev(end, bytes); + q = TclUtfPrev(end, bytes); if (!Tcl_UtfCharComplete(q, (int)(end - q))) { end = q; } |