diff options
author | das <das@noemail.net> | 2007-09-17 11:37:30 (GMT) |
---|---|---|
committer | das <das@noemail.net> | 2007-09-17 11:37:30 (GMT) |
commit | 730ebdfbd62abc90d1b896c18a9fdc5a46d1ce81 (patch) | |
tree | 071255c8714881d4d589d00cd4364faabe4cbd50 | |
parent | 902fcbbbbd5aa7a328fa614dc407f5952ce520a1 (diff) | |
download | tcl-730ebdfbd62abc90d1b896c18a9fdc5a46d1ce81.zip tcl-730ebdfbd62abc90d1b896c18a9fdc5a46d1ce81.tar.gz tcl-730ebdfbd62abc90d1b896c18a9fdc5a46d1ce81.tar.bz2 |
coverity id 100
FossilOrigin-Name: b396c27797d460769f0db117b09f5106bd05c4b8
-rw-r--r-- | unix/tclUnixFile.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/unix/tclUnixFile.c b/unix/tclUnixFile.c index e278eae..cbfff64 100644 --- a/unix/tclUnixFile.c +++ b/unix/tclUnixFile.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclUnixFile.c,v 1.50 2006/08/29 00:36:57 coldstore Exp $ + * RCS: @(#) $Id: tclUnixFile.c,v 1.51 2007/09/17 11:37:30 das Exp $ */ #include "tclInt.h" @@ -886,6 +886,9 @@ TclpObjLink( Tcl_DecrRefCount(dirPtr); } else { target = Tcl_FSGetNativePath(toPtr); + if (target == NULL) { + return NULL; + } if (access(target, F_OK) == -1) { /* * Target doesn't exist. @@ -894,9 +897,6 @@ TclpObjLink( errno = ENOENT; return NULL; } - if (target == NULL) { - return NULL; - } } if (access(src, F_OK) != -1) { |