summaryrefslogtreecommitdiffstats
path: root/generic/tclUtil.c
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tclUtil.c')
-rw-r--r--generic/tclUtil.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/generic/tclUtil.c b/generic/tclUtil.c
index 30cf775..0654f65 100644
--- a/generic/tclUtil.c
+++ b/generic/tclUtil.c
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclUtil.c,v 1.63 2005/07/27 18:24:02 dgp Exp $
+ * RCS: @(#) $Id: tclUtil.c,v 1.64 2005/09/06 14:40:11 dkf Exp $
*/
#include "tclInt.h"
@@ -1057,8 +1057,14 @@ Tcl_ConcatObj(objc, objv)
*/
for (i = 0; i < objc; i++) {
+ List *listRepPtr;
+
objPtr = objv[i];
- if ((objPtr->typePtr != &tclListType) || (objPtr->bytes != NULL)) {
+ if (objPtr->typePtr != &tclListType) {
+ break;
+ }
+ listRepPtr = (List *) objPtr->internalRep.twoPtrValue.ptr1;
+ if (objPtr->bytes != NULL && !listRepPtr->canonicalFlag) {
break;
}
}
@@ -1074,6 +1080,7 @@ Tcl_ConcatObj(objc, objv)
* INT_MAX tells us to always put the new stuff on the end. It
* will be set right in Tcl_ListObjReplace.
*/
+
Tcl_ListObjGetElements(NULL, objv[i], &listc, &listv);
Tcl_ListObjReplace(NULL, objPtr, INT_MAX, 0, listc, listv);
}