diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2016-08-30 13:07:10 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2016-08-30 13:07:10 (GMT) |
commit | 5eb346e0d25b2ae446797b610058911dc3b65a63 (patch) | |
tree | 4c13a17c50a6283243312fe0ed36e17d16d4dfc9 /generic/tclExecute.c | |
parent | 6eb9e4367cece63b5ba975098c2d3ad41915a0fa (diff) | |
parent | d84492f3906d20d05b547a4fa90286fe0a59bb37 (diff) | |
download | tcl-5eb346e0d25b2ae446797b610058911dc3b65a63.zip tcl-5eb346e0d25b2ae446797b610058911dc3b65a63.tar.gz tcl-5eb346e0d25b2ae446797b610058911dc3b65a63.tar.bz2 |
Don't ever allow UTF-8 sequences of more than 4 characters to be generated or parsed, even when TCL_UTF_MAX>4: According to current Unicode standard, a byte string of >4 characters can never form a single UTF-8 character.
And a few minor micro-optimizations related to UTF-8 handling.
Diffstat (limited to 'generic/tclExecute.c')
-rw-r--r-- | generic/tclExecute.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/generic/tclExecute.c b/generic/tclExecute.c index a2a465a..704e494 100644 --- a/generic/tclExecute.c +++ b/generic/tclExecute.c @@ -3173,7 +3173,7 @@ TEBCresume( Tcl_Obj *copyPtr = Tcl_NewListObj(objc - opnd + 1, NULL); Tcl_ListObjAppendElement(NULL, copyPtr, objPtr); - Tcl_ListObjReplace(NULL, copyPtr, LIST_MAX, 0, + Tcl_ListObjReplace(NULL, copyPtr, LIST_MAX, 0, objc - opnd, objv + opnd); Tcl_DecrRefCount(objPtr); objPtr = copyPtr; |