summaryrefslogtreecommitdiffstats
path: root/generic/tclEnsemble.c
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tclEnsemble.c')
-rw-r--r--generic/tclEnsemble.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/generic/tclEnsemble.c b/generic/tclEnsemble.c
index bc92251..c4750c5 100644
--- a/generic/tclEnsemble.c
+++ b/generic/tclEnsemble.c
@@ -9,7 +9,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclEnsemble.c,v 1.4 2010/02/24 10:32:17 dkf Exp $
+ * RCS: @(#) $Id: tclEnsemble.c,v 1.5 2010/03/05 14:34:04 dkf Exp $
*/
#include "tclInt.h"
@@ -204,14 +204,14 @@ TclNamespaceEnsembleCmd(
paramObj = (len > 0 ? objv[1] : NULL);
continue;
case CRT_MAP: {
- Tcl_Obj *patchedDict = NULL, *subcmdObj;
+ Tcl_Obj *patchedDict = NULL, *subcmdWordsObj;
/*
* Verify that the map is sensible.
*/
if (Tcl_DictObjFirst(interp, objv[1], &search,
- &subcmdObj, &listObj, &done) != TCL_OK) {
+ &subcmdWordsObj, &listObj, &done) != TCL_OK) {
if (allocatedMapFlag) {
Tcl_DecrRefCount(mapObj);
}
@@ -262,9 +262,10 @@ TclNamespaceEnsembleCmd(
if (patchedDict == NULL) {
patchedDict = Tcl_DuplicateObj(objv[1]);
}
- Tcl_DictObjPut(NULL, patchedDict, subcmdObj, newList);
+ Tcl_DictObjPut(NULL, patchedDict, subcmdWordsObj,
+ newList);
}
- Tcl_DictObjNext(&search, &subcmdObj, &listObj, &done);
+ Tcl_DictObjNext(&search, &subcmdWordsObj,&listObj, &done);
} while (!done);
if (allocatedMapFlag) {
@@ -491,7 +492,7 @@ TclNamespaceEnsembleCmd(
paramObj = (len > 0 ? objv[1] : NULL);
continue;
case CONF_MAP: {
- Tcl_Obj *patchedDict = NULL, *subcmdObj, **listv;
+ Tcl_Obj *patchedDict = NULL, *subcmdWordsObj, **listv;
const char *cmd;
/*
@@ -499,7 +500,7 @@ TclNamespaceEnsembleCmd(
*/
if (Tcl_DictObjFirst(interp, objv[1], &search,
- &subcmdObj, &listObj, &done) != TCL_OK) {
+ &subcmdWordsObj, &listObj, &done) != TCL_OK) {
goto freeMapAndError;
}
if (done) {
@@ -539,10 +540,11 @@ TclNamespaceEnsembleCmd(
if (patchedDict == NULL) {
patchedDict = Tcl_DuplicateObj(objv[1]);
}
- Tcl_DictObjPut(NULL, patchedDict, subcmdObj,
+ Tcl_DictObjPut(NULL, patchedDict, subcmdWordsObj,
newList);
}
- Tcl_DictObjNext(&search, &subcmdObj, &listObj, &done);
+ Tcl_DictObjNext(&search, &subcmdWordsObj, &listObj,
+ &done);
} while (!done);
if (allocatedMapFlag) {
Tcl_DecrRefCount(mapObj);
@@ -865,14 +867,14 @@ Tcl_SetEnsembleMappingDict(
for (Tcl_DictObjFirst(NULL, mapDict, &search, NULL, &valuePtr, &done);
!done; Tcl_DictObjNext(&search, NULL, &valuePtr, &done)) {
- Tcl_Obj *cmdPtr;
+ Tcl_Obj *cmdObjPtr;
const char *bytes;
- if (Tcl_ListObjIndex(interp, valuePtr, 0, &cmdPtr) != TCL_OK) {
+ if (Tcl_ListObjIndex(interp, valuePtr, 0, &cmdObjPtr) != TCL_OK) {
Tcl_DictObjDone(&search);
return TCL_ERROR;
}
- bytes = TclGetString(cmdPtr);
+ bytes = TclGetString(cmdObjPtr);
if (bytes[0] != ':' || bytes[1] != ':') {
Tcl_AppendResult(interp,
"ensemble target is not a fully-qualified command",
@@ -2311,8 +2313,6 @@ BuildEnsembleConfig(
* Remove pre-existing table.
*/
- Tcl_HashSearch search;
-
ckfree((char *) ensemblePtr->subcommandArrayPtr);
hPtr = Tcl_FirstHashEntry(hash, &search);
while (hPtr != NULL) {