Skip to content
Tcl Source Code Check-in [1d9487bc7e]
Login

Check-in [1d9487bc7e]

Overview
Comment:Fix first part of [ed29806baf]: Tcl_UtfToUniChar reads more than TCL_UTF_MAX bytes. Tcl_UtfToUniChar() now never reads more than TCL_UTF_MAX bytes any more. Since the UtfToUtf encoder/decoder now uses TclUtfToUCS4() it doesn't join 2 surrogates as 2 x 3-byte sequences any more. Actually, it shouldn't, because such sequences are invalid UTF-8. Therefore, added the ucs2 constraint to testcase encoding-15.4. Let's see how TIP #573 goes, this TIP should make this change official. Other callers of Tcl_UtfToUniChar() needs to be revised for the same problem. Most callers will need to change Tcl_UtfToUniChar() -> TclUtfToUCS4() and Tcl_UtfCharComplete() -> TclUCS4Complete(), but that's not done yet.
Timelines: family | ancestors | descendants | both | core-8-branch
Files: files | file ages | folders
SHA3-256: 1d9487bc7e6c6941dbbe0fcf24fc5d29a1b704c45f9373735dac31b0d572ae9c
User & Date: jan.nijtmans on 2020-05-01 14:20:21.319
Other Links: branch diff | manifest | tags
Context
2020-05-01
14:53
Never mind remark about TIP #573 in previous commit: Test failure was due to typo. Fixed now. check-in: 15b715b177 user: jan.nijtmans tags: core-8-branch
14:44
Merge 8.7 check-in: 056c1aad28 user: jan.nijtmans tags: trunk
14:20
Fix first part of [ed29806baf]: Tcl_UtfToUniChar reads more than TCL_UTF_MAX bytes. Tcl_UtfToUniCha... check-in: 1d9487bc7e user: jan.nijtmans tags: core-8-branch
13:38
Fix first part of [ed29806baf]: Tcl_UtfToUniChar reads more than TCL_UTF_MAX bytes. Tcl_UtfToUniChar... check-in: 5f2bb912cf user: jan.nijtmans tags: core-8-6-branch
2020-04-30
21:07
merge 8.6 check-in: 1921d73497 user: dgp tags: core-8-branch
Changes