diff options
| author | dgp@users.sourceforge.net <dgp> | 2004-12-02 23:24:54 (GMT) |
|---|---|---|
| committer | dgp@users.sourceforge.net <dgp> | 2004-12-02 23:24:54 (GMT) |
| commit | 805f90b35db4b377cb6513e74396021d6f5c72d1 (patch) | |
| tree | c793de357ee6b036d50f0a0bc464a7cd38856f2d /generic/tclEncoding.c | |
| parent | 57c17fb9077ca9674579cd3061f19904f547dcb4 (diff) | |
| download | tcl-805f90b35db4b377cb6513e74396021d6f5c72d1.zip tcl-805f90b35db4b377cb6513e74396021d6f5c72d1.tar.gz tcl-805f90b35db4b377cb6513e74396021d6f5c72d1.tar.bz2 | |
* generic/tclUtil.c (TclSetProcessGlobalValue): Handle the case
where a ProcessGlobalValue might be assigned to itself.
* generic/tclEncoding.c (MakeFileMap): Correct refcounting errors
managing values returned by TclPathPart (with refCount of 1!) that
led to a memory leak. [Bug 1077474].
Diffstat (limited to 'generic/tclEncoding.c')
| -rw-r--r-- | generic/tclEncoding.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/generic/tclEncoding.c b/generic/tclEncoding.c index 1d2c0b8..3cbf450 100644 --- a/generic/tclEncoding.c +++ b/generic/tclEncoding.c @@ -8,7 +8,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclEncoding.c,v 1.29 2004/12/01 23:18:50 dgp Exp $ + * RCS: @(#) $Id: tclEncoding.c,v 1.30 2004/12/02 23:24:57 dgp Exp $ */ #include "tclInt.h" @@ -410,10 +410,10 @@ MakeFileMap() Tcl_Obj *encodingName, *file; file = TclPathPart(NULL, filev[j], TCL_PATH_TAIL); - Tcl_IncrRefCount(file); encodingName = TclPathPart(NULL, file, TCL_PATH_ROOT); - Tcl_IncrRefCount(encodingName); Tcl_DictObjPut(NULL, map, encodingName, directory); + Tcl_DecrRefCount(file); + Tcl_DecrRefCount(encodingName); } Tcl_DecrRefCount(matchFileList); Tcl_DecrRefCount(directory); |
