summaryrefslogtreecommitdiffstats
path: root/generic/tclStringObj.c
diff options
context:
space:
mode:
authormsofer <msofer@noemail.net>2006-01-23 11:24:36 (GMT)
committermsofer <msofer@noemail.net>2006-01-23 11:24:36 (GMT)
commitd8e95c37f5538602c67685ab0e8464ba46b714b0 (patch)
tree2efebf2b113b58ff153bab367d00984aadd0eab9 /generic/tclStringObj.c
parentbc94046e5b3cf918c740567be71d420871ecde41 (diff)
downloadtcl-d8e95c37f5538602c67685ab0e8464ba46b714b0.zip
tcl-d8e95c37f5538602c67685ab0e8464ba46b714b0.tar.gz
tcl-d8e95c37f5538602c67685ab0e8464ba46b714b0.tar.bz2
* generic/tclStringObj.c: fixed incorrect handling of internal rep
in Tcl_GetRange [Bug 1410553]. Thanks to twylite and Peter Spjuth. FossilOrigin-Name: b23e99e48d8c05bca1aaec4282b50311d9c4646f
Diffstat (limited to 'generic/tclStringObj.c')
-rw-r--r--generic/tclStringObj.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/generic/tclStringObj.c b/generic/tclStringObj.c
index 5925451..9ec2f63 100644
--- a/generic/tclStringObj.c
+++ b/generic/tclStringObj.c
@@ -33,7 +33,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclStringObj.c,v 1.32 2003/02/19 16:43:28 das Exp $ */
+ * RCS: @(#) $Id: tclStringObj.c,v 1.32.2.1 2006/01/23 11:24:36 msofer Exp $ */
#include "tclInt.h"
@@ -642,7 +642,7 @@ Tcl_GetRange(objPtr, first, last)
stringPtr = GET_STRING(objPtr);
}
- if (stringPtr->numChars == objPtr->length) {
+ if (objPtr->bytes && stringPtr->numChars == objPtr->length) {
char *str = Tcl_GetString(objPtr);
/*