diff options
author | dgp <dgp@users.sourceforge.net> | 2017-09-12 12:11:51 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2017-09-12 12:11:51 (GMT) |
commit | b6bf5c825247827226680949d75a3b590b6631a7 (patch) | |
tree | aa3f87d0b3175808f01fc1cbb3d3d95c82baa628 /generic | |
parent | 65e82cdc180bb124392469acc17c1400641a3452 (diff) | |
download | tcl-b6bf5c825247827226680949d75a3b590b6631a7.zip tcl-b6bf5c825247827226680949d75a3b590b6631a7.tar.gz tcl-b6bf5c825247827226680949d75a3b590b6631a7.tar.bz2 |
When we invalidate the string rep of a dict, that's a sign we need to
free all the intreps of that dict as well.
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclDictObj.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/generic/tclDictObj.c b/generic/tclDictObj.c index f4e15a6..b312fe1 100644 --- a/generic/tclDictObj.c +++ b/generic/tclDictObj.c @@ -909,7 +909,11 @@ InvalidateDictChain( assert( dict != NULL); do { + dict->refCount++; TclInvalidateStringRep(dictObj); + Tcl_FreeIntRep(dictObj); + DictSetIntRep(dictObj, dict); + dict->epoch++; dictObj = dict->chain; if (dictObj == NULL) { |