diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | generic/tclVar.c | 10 |
2 files changed, 8 insertions, 7 deletions
@@ -1,3 +1,8 @@ +2010-07-28 Miguel Sofer <msofer@users.sf.net> + + * generic/tclVar.c: fix for crash [Bug 3037525]: lose fickle + optimisation in TclDeleteVars (used for runtime-created locals) + 2010-07-25 Jan Nijtmans <nijtmans@users.sf.net> * generic/tclInt.h [Bug 3030870] make itcl 3.x built with pre-8.6 work in 8.6 diff --git a/generic/tclVar.c b/generic/tclVar.c index 36db617..c23681f 100644 --- a/generic/tclVar.c +++ b/generic/tclVar.c @@ -16,7 +16,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclVar.c,v 1.160.2.9 2010/02/03 13:28:44 dkf Exp $ + * RCS: @(#) $Id: tclVar.c,v 1.160.2.10 2010/07/31 18:10:11 msofer Exp $ */ #include "tclInt.h" @@ -4521,14 +4521,10 @@ TclDeleteVars( } for (varPtr = VarHashFirstVar(tablePtr, &search); varPtr != NULL; - varPtr = VarHashNextVar(&search)) { - /* - * Lie about the validity of the hashtable entry. In this way the - * variables will be deleted by VarHashDeleteTable. - */ + varPtr = VarHashFirstVar(tablePtr, &search)) { - VarHashInvalidateEntry(varPtr); UnsetVarStruct(varPtr, NULL, iPtr, VarHashGetKey(varPtr), NULL, flags); + VarHashDeleteEntry(varPtr); } VarHashDeleteTable(tablePtr); } |