diff options
author | dgp <dgp@users.sourceforge.net> | 2005-09-07 15:31:09 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2005-09-07 15:31:09 (GMT) |
commit | 0a42d952ff2cba9243fc2f432420bffb52aa9e70 (patch) | |
tree | 481a4f34db391c90f180dc321a489ae8e50bff99 /tests/utf.test | |
parent | 2a03bdad453a632583f84f71bf5091c682999d90 (diff) | |
download | tcl-0a42d952ff2cba9243fc2f432420bffb52aa9e70.zip tcl-0a42d952ff2cba9243fc2f432420bffb52aa9e70.tar.gz tcl-0a42d952ff2cba9243fc2f432420bffb52aa9e70.tar.bz2 |
* generic/tclUtf.c (Tcl_UniCharToUtf): Corrected handling of negative
* tests/utf.test (utf-1.5): Tcl_UniChar input value. Incorrect
handling was producing byte sequences outside of Tcl's legal internal
encoding. [Bug 1283976].
Diffstat (limited to 'tests/utf.test')
-rw-r--r-- | tests/utf.test | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/utf.test b/tests/utf.test index 56a3acb..d5df773 100644 --- a/tests/utf.test +++ b/tests/utf.test @@ -8,7 +8,7 @@ # See the file "license.terms" for information on usage and redistribution # of this file, and for a DISCLAIMER OF ALL WARRANTIES. # -# RCS: @(#) $Id: utf.test,v 1.12 2003/10/08 15:24:21 dgp Exp $ +# RCS: @(#) $Id: utf.test,v 1.13 2005/09/07 15:31:10 dgp Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest 2 @@ -29,6 +29,9 @@ test utf-1.3 {Tcl_UniCharToUtf: 2 byte sequences} { test utf-1.4 {Tcl_UniCharToUtf: 3 byte sequences} { set x "\u4e4e" } [bytestring "\xe4\xb9\x8e"] +test utf-1.5 {Tcl_UniCharToUtf: negative Tcl_UniChar} { + string length [format %c -1] +} 1 test utf-2.1 {Tcl_UtfToUniChar: low ascii} { string length "abc" |