summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2020-04-28 18:29:36 (GMT)
committerdgp <dgp@users.sourceforge.net>2020-04-28 18:29:36 (GMT)
commit09a297b63d11535a51dcb0163973a3dfeb5f70b9 (patch)
treeb117db874aae8f8c0433e39ed2b3c7851dc0d28d /generic
parentdc53acd0953d16e0699c1ae80066da2bf784e26c (diff)
downloadtcl-09a297b63d11535a51dcb0163973a3dfeb5f70b9.zip
tcl-09a297b63d11535a51dcb0163973a3dfeb5f70b9.tar.gz
tcl-09a297b63d11535a51dcb0163973a3dfeb5f70b9.tar.bz2
Proposed fix.
Diffstat (limited to 'generic')
-rw-r--r--generic/tclParse.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/generic/tclParse.c b/generic/tclParse.c
index e95768d..34d9bed 100644
--- a/generic/tclParse.c
+++ b/generic/tclParse.c
@@ -868,13 +868,13 @@ TclParseBackslash(
* No hexdigits -> This is just "u".
*/
result = 'u';
- } else if (((result & 0xDC00) == 0xD800) && (count == 6)
+ } else if (((result & 0xFC00) == 0xD800) && (count == 6)
&& (p[5] == '\\') && (p[6] == 'u') && (numBytes >= 10)) {
/* If high surrogate is immediately followed by a low surrogate
* escape, combine them into one character. */
int low;
int count2 = ParseHex(p+7, 4, &low);
- if ((count2 == 4) && ((low & 0xDC00) == 0xDC00)) {
+ if ((count2 == 4) && ((low & 0xFC00) == 0xDC00)) {
result = ((result & 0x3FF)<<10 | (low & 0x3FF)) + 0x10000;
count += count2 + 2;
}