summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authormig <mig>2013-01-05 00:36:25 (GMT)
committermig <mig>2013-01-05 00:36:25 (GMT)
commit8ed264286869e58830dbd831907ca25189123d6c (patch)
tree90d0fbe9cf4d226e9bf4aa40b1be7b88ada3ecb4 /generic
parentf5f116ff983872cb0da47325218d26f0348454f5 (diff)
downloadtcl-8ed264286869e58830dbd831907ca25189123d6c.zip
tcl-8ed264286869e58830dbd831907ca25189123d6c.tar.gz
tcl-8ed264286869e58830dbd831907ca25189123d6c.tar.bz2
fix the new assertion, it should not trigger when an expansion is in progress
Diffstat (limited to 'generic')
-rw-r--r--generic/tclExecute.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/generic/tclExecute.c b/generic/tclExecute.c
index 496bd9b..fbf8f6d 100644
--- a/generic/tclExecute.c
+++ b/generic/tclExecute.c
@@ -251,12 +251,15 @@ VarHashCreateVar(
* otherwise, push objResultPtr. If (result < 0), objResultPtr already
* has the correct reference count.
*
- * We use the new compile-time assertions to cheack that nCleanup is constant
+ * We use the new compile-time assertions to check that nCleanup is constant
* and within range.
*/
+/* Verify the stack depth, only when no expansion is in progress */
+
#if TCL_COMPILE_DEBUG
-#define CHECK_STACK() assert(CURR_DEPTH <= codePtr->maxStackDepth)
+#define CHECK_STACK() \
+ assert((auxObjList != NULL) || (CURR_DEPTH <= codePtr->maxStackDepth))
#else
#define CHECK_STACK()
#endif