summaryrefslogtreecommitdiffstats
path: root/generic/tclExecute.c
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tclExecute.c')
-rw-r--r--generic/tclExecute.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/generic/tclExecute.c b/generic/tclExecute.c
index 3fac4ea..9597075 100644
--- a/generic/tclExecute.c
+++ b/generic/tclExecute.c
@@ -14,7 +14,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.458 2009/12/09 17:55:01 msofer Exp $
+ * RCS: @(#) $Id: tclExecute.c,v 1.459 2009/12/10 16:54:01 msofer Exp $
*/
#include "tclInt.h"
@@ -1972,20 +1972,21 @@ TclExecuteByteCode(
* execution stack is large enough to execute this ByteCode.
*/
- if (!codePtr) {
resumeCoroutine:
+ if (!codePtr) {
+ CoroutineData *corPtr = iPtr->execEnvPtr->corPtr;
/*
* Reawakening a suspended coroutine: the [yield] command is
* returning.
*/
- NRE_ASSERT(iPtr->execEnvPtr->corPtr->eePtr == iPtr->execEnvPtr);
- NRE_ASSERT(iPtr->execEnvPtr->corPtr != NULL);
- NRE_ASSERT(iPtr->execEnvPtr->corPtr->eePtr == iPtr->execEnvPtr);
- NRE_ASSERT(COR_IS_SUSPENDED(iPtr->execEnvPtr->corPtr));
+ NRE_ASSERT(corPtr != NULL);
+ NRE_ASSERT(corPtr->eePtr == iPtr->execEnvPtr);
+ NRE_ASSERT(COR_IS_SUSPENDED(corPtr));
OBP = iPtr->execEnvPtr->bottomPtr;
- iPtr->execEnvPtr->corPtr->stackLevel = &TAUX;
+ corPtr->stackLevel = &TAUX;
+ corPtr->base.cmdFramePtr->nextPtr = corPtr->caller.cmdFramePtr;
if (iPtr->execEnvPtr->rewind) {
TRESULT = TCL_ERROR;
}
@@ -2835,7 +2836,8 @@ TclExecuteByteCode(
goto nonRecursiveCallStart;
} else {
CoroutineData *corPtr = iPtr->execEnvPtr->corPtr;
-
+
+ codePtr = NULL;
corPtr->callerBP = BP;
goto resumeCoroutine;
}