diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-02-07 20:53:36 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-02-07 20:53:36 (GMT) |
commit | 9c98dd1bc4134808b627aba5937255262290f0df (patch) | |
tree | ceb0c0bd83b5ce682a69df5a518c42df3380abd5 /generic | |
parent | 53c8d55150c7734dafd36205c098365a910c74b8 (diff) | |
parent | 90de673f3290590440628bd2b3dc3b4550a17bd3 (diff) | |
download | tcl-9c98dd1bc4134808b627aba5937255262290f0df.zip tcl-9c98dd1bc4134808b627aba5937255262290f0df.tar.gz tcl-9c98dd1bc4134808b627aba5937255262290f0df.tar.bz2 |
Merge 8.7
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclEncoding.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/generic/tclEncoding.c b/generic/tclEncoding.c index 7bdba96..63ebdf4 100644 --- a/generic/tclEncoding.c +++ b/generic/tclEncoding.c @@ -3306,9 +3306,7 @@ TableToUtfProc( } else if (PROFILE_REPLACE(flags)) { ch = UNICODE_REPLACE_CHAR; } else { - char chbuf[2]; - chbuf[0] = byte; chbuf[1] = 0; - Tcl_UtfToUniChar(chbuf, &ch); + ch = (Tcl_UniChar)byte; } } else { ch = toUnicode[byte][*((unsigned char *)++src)]; @@ -3328,9 +3326,7 @@ TableToUtfProc( if (PROFILE_REPLACE(flags)) { ch = UNICODE_REPLACE_CHAR; } else { - char chbuf[2]; - chbuf[0] = byte; chbuf[1] = 0; - Tcl_UtfToUniChar(chbuf, &ch); + ch = (Tcl_UniChar)byte; } } |