diff options
-rw-r--r-- | ChangeLog | 11 | ||||
-rw-r--r-- | generic/tclBasic.c | 14 | ||||
-rw-r--r-- | generic/tclExecute.c | 6 | ||||
-rw-r--r-- | generic/tclParse.c | 5 |
4 files changed, 14 insertions, 22 deletions
@@ -1,15 +1,18 @@ 2008-07-14 Miguel Sofer <msofer@users.sf.net> + * generic/tclBasic.c.: Embedded Tcl_Canceled() calls into + * generic/tclExecute.c: TclInterpReady(). + * generic/tclParse.c: + * generic/tclVar.c: fix error message - * generic/tclParse.c: - * tests/parse.test: remove unnecessary numLevel management - [Bug 2017583] + * generic/tclParse.c: remove unnecessary numLevel management + * tests/parse.test: [Bug 2017583] * generic/tclBasic.c.: NRE left too many calls to * generic/tclExecute.c: TclResetCancellation lying around: it * generic/tclProc.c: only needs to be called prior to any - iPtr->numLevels++. Thanks mistachkin. + iPtr->numLevels++. Thanks mistachkin. * generic/tclBasic.c: TclResetCancellation() calls were misplaced (merge mishap); stray //. Thanks patthoyts. diff --git a/generic/tclBasic.c b/generic/tclBasic.c index 07b3fb5..e2d3712 100644 --- a/generic/tclBasic.c +++ b/generic/tclBasic.c @@ -16,7 +16,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclBasic.c,v 1.308 2008/07/14 00:11:32 msofer Exp $ + * RCS: @(#) $Id: tclBasic.c,v 1.309 2008/07/14 01:38:00 msofer Exp $ */ #include "tclInt.h" @@ -3617,6 +3617,10 @@ TclInterpReady( return TCL_ERROR; } + if (TCL_OK != Tcl_Canceled(interp, TCL_LEAVE_ERR_MSG)) { + return TCL_ERROR; + } + /* * Check depth of nested calls to Tcl_Eval: if this gets too large, it's * probably because of an infinite loop somewhere. @@ -3934,10 +3938,6 @@ Tcl_EvalObjv( iPtr->numLevels++; result = TclInterpReady(interp); - if (result == TCL_OK) { - result = Tcl_Canceled(interp, TCL_LEAVE_ERR_MSG); - } - if ((result != TCL_OK) || (objc == 0)) { iPtr->lookupNsPtr = NULL; iPtr->numLevels--; @@ -5979,10 +5979,6 @@ TclObjInvoke( return TCL_ERROR; } - if (Tcl_Canceled(interp, TCL_LEAVE_ERR_MSG) == TCL_ERROR) { - return TCL_ERROR; - } - cmdName = TclGetString(objv[0]); hTblPtr = iPtr->hiddenCmdTablePtr; if (hTblPtr != NULL) { diff --git a/generic/tclExecute.c b/generic/tclExecute.c index 0412034..8e6a056 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.378 2008/07/14 00:11:33 msofer Exp $ + * RCS: @(#) $Id: tclExecute.c,v 1.379 2008/07/14 01:38:00 msofer Exp $ */ #include "tclInt.h" @@ -1506,10 +1506,6 @@ TclCompileObj( return NULL; } - if (Tcl_Canceled(interp, TCL_LEAVE_ERR_MSG) == TCL_ERROR) { - return NULL; - } - namespacePtr = iPtr->varFramePtr->nsPtr; /* diff --git a/generic/tclParse.c b/generic/tclParse.c index 1020979..a6abd52 100644 --- a/generic/tclParse.c +++ b/generic/tclParse.c @@ -12,7 +12,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclParse.c,v 1.67 2008/07/14 00:57:28 msofer Exp $ + * RCS: @(#) $Id: tclParse.c,v 1.68 2008/07/14 01:38:01 msofer Exp $ */ #include "tclInt.h" @@ -2167,9 +2167,6 @@ TclSubstTokens( case TCL_TOKEN_COMMAND: { code = TclInterpReady(interp); if (code == TCL_OK) { - code = Tcl_Canceled(interp, TCL_LEAVE_ERR_MSG); - } - if (code == TCL_OK) { /* TIP #280: Transfer line information to nested command */ code = TclEvalEx(interp, tokenPtr->start+1, tokenPtr->size-2, 0, line); |