summaryrefslogtreecommitdiffstats
path: root/generic/tclStringObj.c
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tclStringObj.c')
-rw-r--r--generic/tclStringObj.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/generic/tclStringObj.c b/generic/tclStringObj.c
index 0a38836..261e01f 100644
--- a/generic/tclStringObj.c
+++ b/generic/tclStringObj.c
@@ -2966,9 +2966,25 @@ TclStringCatObjv(
Tcl_GetStringFromObj(objPtr, &numBytes); /* PANIC? */
if (numBytes == 0) {
+ if (pendingPtr && pendingPtr->bytes) {
+ /*
+ * Generating string rep of objPtr also
+ * generated string rep of pendingPtr.
+ */
+ if (pendingPtr->length) {
+ /* Can this happen? */
+ goto foo;
+ } else {
+ /* string-29.14 */
+ first = objc - 1;
+ last = 0;
+ pendingPtr = NULL;
+ }
+ }
continue;
}
last = objc - oc;
+foo:
if (pendingPtr) {
Tcl_GetStringFromObj(pendingPtr, &length); /* PANIC? */
pendingPtr = NULL;