summaryrefslogtreecommitdiffstats
path: root/generic/tclExecute.c
diff options
context:
space:
mode:
authormsofer <msofer@noemail.net>2003-06-10 19:58:25 (GMT)
committermsofer <msofer@noemail.net>2003-06-10 19:58:25 (GMT)
commit4fcfc76871ce156608f48eee73342fea5ae7046e (patch)
treea89c6d5cb9c9431ba2df9e76e0b0de0ee9bcae8c /generic/tclExecute.c
parentc4606822a67fcde9418759c942b5f341e3b93a27 (diff)
downloadtcl-4fcfc76871ce156608f48eee73342fea5ae7046e.zip
tcl-4fcfc76871ce156608f48eee73342fea5ae7046e.tar.gz
tcl-4fcfc76871ce156608f48eee73342fea5ae7046e.tar.bz2
* generic/tclBasic.c:
* generic/tclExecute.c: let TclExecuteObjvInternal call TclInterpReady instead of relying on its callers to do so; fix for the part of [Bug 495830] that is new in 8.4. * tests/interp.test: Added tests 18.9 (knownbug) and 18.10 FossilOrigin-Name: 3ef5e4db8f07f6e68d1bf1a454c461551cd6ebf1
Diffstat (limited to 'generic/tclExecute.c')
-rw-r--r--generic/tclExecute.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/generic/tclExecute.c b/generic/tclExecute.c
index 272d939..578be7e 100644
--- a/generic/tclExecute.c
+++ b/generic/tclExecute.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: tclExecute.c,v 1.94.2.2 2003/04/18 20:06:05 hobbs Exp $
+ * RCS: @(#) $Id: tclExecute.c,v 1.94.2.3 2003/06/10 19:58:35 msofer Exp $
*/
#include "tclInt.h"
@@ -895,7 +895,9 @@ TclCompEvalObj(interp, objPtr)
* Check that the interpreter is ready to execute scripts
*/
+ iPtr->numLevels++;
if (TclInterpReady(interp) == TCL_ERROR) {
+ iPtr->numLevels--;
return TCL_ERROR;
}
@@ -917,6 +919,7 @@ TclCompEvalObj(interp, objPtr)
iPtr->errorLine = 1;
result = tclByteCodeType.setFromAnyProc(interp, objPtr);
if (result != TCL_OK) {
+ iPtr->numLevels--;
return result;
}
iPtr->evalFlags = 0;
@@ -976,9 +979,7 @@ TclCompEvalObj(interp, objPtr)
*/
codePtr->refCount++;
- iPtr->numLevels++;
result = TclExecuteByteCode(interp, codePtr);
- iPtr->numLevels--;
codePtr->refCount--;
if (codePtr->refCount <= 0) {
TclCleanupByteCode(codePtr);
@@ -986,6 +987,8 @@ TclCompEvalObj(interp, objPtr)
} else {
result = TCL_OK;
}
+ iPtr->numLevels--;
+
/*
* If no commands at all were executed, check for asynchronous