diff options
author | dkf <dkf@noemail.net> | 2011-08-16 13:55:06 (GMT) |
---|---|---|
committer | dkf <dkf@noemail.net> | 2011-08-16 13:55:06 (GMT) |
commit | 5d98123e6350a0c44e2cd4e0772e2723d9e45779 (patch) | |
tree | dfac520f6bcb71143cd81124598bdb9d07e00d0b /generic/tclVar.c | |
parent | 49a961a6cea1ec12e727337234ae59b5f6478e58 (diff) | |
download | tcl-5d98123e6350a0c44e2cd4e0772e2723d9e45779.zip tcl-5d98123e6350a0c44e2cd4e0772e2723d9e45779.tar.gz tcl-5d98123e6350a0c44e2cd4e0772e2723d9e45779.tar.bz2 |
Small changes to quell gcc warnings and make message generation less ugly.
FossilOrigin-Name: df6fb9a914fd80a4202414f387d789f9e2c5ace8
Diffstat (limited to 'generic/tclVar.c')
-rw-r--r-- | generic/tclVar.c | 7 |
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; } |