diff options
author | vasiljevic <vasiljevic@noemail.net> | 2003-12-17 09:32:35 (GMT) |
---|---|---|
committer | vasiljevic <vasiljevic@noemail.net> | 2003-12-17 09:32:35 (GMT) |
commit | bb9fc54120458759ea3b71bb5269abdc837ff859 (patch) | |
tree | 5e34991c51f4911b00b500e88aa08e599be13c5a /generic/tclIOUtil.c | |
parent | 8e74c4a9a914f794ba0c97a7f1bbb52821a0fc3c (diff) | |
download | tcl-bb9fc54120458759ea3b71bb5269abdc837ff859.zip tcl-bb9fc54120458759ea3b71bb5269abdc837ff859.tar.gz tcl-bb9fc54120458759ea3b71bb5269abdc837ff859.tar.bz2 |
Merged fixes for Tcl Bug #839519 and Tcl Bug #861515.
Those are already applied to the head.
FossilOrigin-Name: fe3c10c7526ba8836c93ad4fa155c21963d07c70
Diffstat (limited to 'generic/tclIOUtil.c')
-rw-r--r-- | generic/tclIOUtil.c | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/generic/tclIOUtil.c b/generic/tclIOUtil.c index de12596..3dcb564 100644 --- a/generic/tclIOUtil.c +++ b/generic/tclIOUtil.c @@ -17,7 +17,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclIOUtil.c,v 1.77.2.12 2003/11/20 19:05:44 vincentdarley Exp $ + * RCS: @(#) $Id: tclIOUtil.c,v 1.77.2.13 2003/12/17 09:32:35 vasiljevic Exp $ */ #include "tclInt.h" @@ -499,7 +499,7 @@ typedef struct ThreadSpecificData { FilesystemRecord *filesystemList; } ThreadSpecificData; -Tcl_ThreadDataKey dataKey; +static Tcl_ThreadDataKey dataKey; /* * Declare fallback support function and @@ -2509,7 +2509,8 @@ Tcl_FSGetCwd(interp) * we'll always be in the 'else' branch below which * is simpler. */ - FsUpdateCwd(norm); + FsUpdateCwd(norm); + Tcl_DecrRefCount(norm); } Tcl_DecrRefCount(retVal); } @@ -2555,6 +2556,7 @@ Tcl_FSGetCwd(interp) Tcl_DecrRefCount(norm); } else { FsUpdateCwd(norm); + Tcl_DecrRefCount(norm); } Tcl_DecrRefCount(retVal); } else { @@ -5263,15 +5265,16 @@ Tcl_FSGetTranslatedPath(interp, pathPtr) srcFsPathPtr = (FsPath*) PATHOBJ(pathPtr); if (srcFsPathPtr->translatedPathPtr == NULL) { if (PATHFLAGS(pathPtr) != 0) { - return Tcl_FSGetNormalizedPath(interp, pathPtr); + retObj = Tcl_FSGetNormalizedPath(interp, pathPtr); + } else { + /* + * It is a pure absolute, normalized path object. + * This is something like being a 'pure list'. The + * object's string, translatedPath and normalizedPath + * are all identical. + */ + retObj = srcFsPathPtr->normPathPtr; } - /* - * It is a pure absolute, normalized path object. - * This is something like being a 'pure list'. The - * object's string, translatedPath and normalizedPath - * are all identical. - */ - retObj = srcFsPathPtr->normPathPtr; } else { /* It is an ordinary path object */ retObj = srcFsPathPtr->translatedPathPtr; |