diff options
author | mig <mig> | 2013-12-06 00:02:16 (GMT) |
---|---|---|
committer | mig <mig> | 2013-12-06 00:02:16 (GMT) |
commit | ec2f589b56bb7241ee7f7b60aad33ccdfa46ec98 (patch) | |
tree | 5251d98bedc040c00f0707c92325d542372a8db5 /generic | |
parent | ff9c2d4ad9a37c50a4921bada422365ae85d5ac1 (diff) | |
download | tcl-ec2f589b56bb7241ee7f7b60aad33ccdfa46ec98.zip tcl-ec2f589b56bb7241ee7f7b60aad33ccdfa46ec98.tar.gz tcl-ec2f589b56bb7241ee7f7b60aad33ccdfa46ec98.tar.bz2 |
tighter mem management
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclCompCmds.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/generic/tclCompCmds.c b/generic/tclCompCmds.c index 78c6c5a..da14af1 100644 --- a/generic/tclCompCmds.c +++ b/generic/tclCompCmds.c @@ -2602,16 +2602,14 @@ CompileEachloopCmd( */ infoPtr = ckalloc(sizeof(ForeachInfo) - + numLists * sizeof(ForeachVarList *)); + + (numLists - 1) * sizeof(ForeachVarList *)); infoPtr->numLists = numLists; - infoPtr->firstValueTemp = collect; - infoPtr->loopCtTemp = 0; for (loopIndex = 0; loopIndex < numLists; loopIndex++) { ForeachVarList *varListPtr; numVars = varcList[loopIndex]; varListPtr = ckalloc(sizeof(ForeachVarList) - + numVars * sizeof(int)); + + (numVars - 1) * sizeof(int)); varListPtr->numVars = numVars; for (j = 0; j < numVars; j++) { const char *varName = varvList[loopIndex][j]; |