diff options
Diffstat (limited to 'generic/tclNamesp.c')
-rw-r--r-- | generic/tclNamesp.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/generic/tclNamesp.c b/generic/tclNamesp.c index dee324c..e32e0ba 100644 --- a/generic/tclNamesp.c +++ b/generic/tclNamesp.c @@ -22,7 +22,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclNamesp.c,v 1.203 2010/02/24 10:45:04 dkf Exp $ + * RCS: @(#) $Id: tclNamesp.c,v 1.204 2010/03/05 14:34:04 dkf Exp $ */ #include "tclInt.h" @@ -1638,13 +1638,12 @@ DoImport( cmdPtr = Tcl_GetHashValue(hPtr); if (found != NULL && cmdPtr->deleteProc == DeleteImportedCmd) { Command *overwrite = Tcl_GetHashValue(found); - Command *link = cmdPtr; + Command *linkCmd = cmdPtr; - while (link->deleteProc == DeleteImportedCmd) { - ImportedCmdData *dataPtr = link->objClientData; - - link = dataPtr->realCmdPtr; - if (overwrite == link) { + while (linkCmd->deleteProc == DeleteImportedCmd) { + dataPtr = linkCmd->objClientData; + linkCmd = dataPtr->realCmdPtr; + if (overwrite == linkCmd) { Tcl_AppendResult(interp, "import pattern \"", pattern, "\" would create a loop containing command \"", Tcl_DStringValue(&ds), "\"", NULL); |