diff options
author | mig <mig> | 2011-08-01 17:15:19 (GMT) |
---|---|---|
committer | mig <mig> | 2011-08-01 17:15:19 (GMT) |
commit | 7cafb9729cb8db722600b80cd3b1c9536ca46519 (patch) | |
tree | 8f01d54611133845b2680006211754b6c63c5e0a /generic/tclProc.c | |
parent | 666118190e342c616ccffff20d1f7d0f14abe242 (diff) | |
download | tcl-7cafb9729cb8db722600b80cd3b1c9536ca46519.zip tcl-7cafb9729cb8db722600b80cd3b1c9536ca46519.tar.gz tcl-7cafb9729cb8db722600b80cd3b1c9536ca46519.tar.bz2 |
* generic/tclProc.c (TclProcCompileProc): fix for leak of resolveInfo when recompiling procs, [Bug 3383616]. Thx go to Gustaf Neumann for detecting the bug and providing the fix.
Diffstat (limited to 'generic/tclProc.c')
-rw-r--r-- | generic/tclProc.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/generic/tclProc.c b/generic/tclProc.c index a2de765..48f472f 100644 --- a/generic/tclProc.c +++ b/generic/tclProc.c @@ -2063,6 +2063,13 @@ TclProcCompileProc( CompiledLocal *toFree = clPtr; clPtr = clPtr->nextPtr; + if (toFree->resolveInfo) { + if (toFree->resolveInfo->deleteProc) { + toFree->resolveInfo->deleteProc(toFree->resolveInfo); + } else { + ckfree(toFree->resolveInfo); + } + } ckfree(toFree); } procPtr->numCompiledLocals = procPtr->numArgs; |