summaryrefslogtreecommitdiffstats
path: root/generic/tclVar.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2011-08-16 13:55:06 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2011-08-16 13:55:06 (GMT)
commit2b06c7f54bcd83f0b688de71e23b603a2586974c (patch)
treedfac520f6bcb71143cd81124598bdb9d07e00d0b /generic/tclVar.c
parent268e10049df3ec1784fdaae40b0644ce5f482653 (diff)
downloadtcl-2b06c7f54bcd83f0b688de71e23b603a2586974c.zip
tcl-2b06c7f54bcd83f0b688de71e23b603a2586974c.tar.gz
tcl-2b06c7f54bcd83f0b688de71e23b603a2586974c.tar.bz2
Small changes to quell gcc warnings and make message generation less ugly.
Diffstat (limited to 'generic/tclVar.c')
-rw-r--r--generic/tclVar.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/generic/tclVar.c b/generic/tclVar.c
index 62bf1c4..4df5d43 100644
--- a/generic/tclVar.c
+++ b/generic/tclVar.c
@@ -3077,21 +3077,18 @@ ArrayStartSearchCmd(
hPtr = Tcl_CreateHashEntry(&iPtr->varSearches, varPtr, &isNew);
if (isNew) {
searchPtr->id = 1;
- Tcl_AppendResult(interp, "s-1-", varName, NULL);
varPtr->flags |= VAR_SEARCH_ACTIVE;
searchPtr->nextPtr = NULL;
} else {
- char string[TCL_INTEGER_SPACE];
-
searchPtr->id = ((ArraySearch *) Tcl_GetHashValue(hPtr))->id + 1;
- TclFormatInt(string, searchPtr->id);
- Tcl_AppendResult(interp, "s-", string, "-", varName, NULL);
searchPtr->nextPtr = Tcl_GetHashValue(hPtr);
}
searchPtr->varPtr = varPtr;
searchPtr->nextEntry = VarHashFirstEntry(varPtr->value.tablePtr,
&searchPtr->search);
Tcl_SetHashValue(hPtr, searchPtr);
+ Tcl_SetObjResult(interp,
+ Tcl_ObjPrintf("s-%d-%s", searchPtr->id, varName));
return TCL_OK;
}