summaryrefslogtreecommitdiffstats
path: root/win/tclWinLoad.c
diff options
context:
space:
mode:
authornijtmans <nijtmans>2010-04-13 13:37:28 (GMT)
committernijtmans <nijtmans>2010-04-13 13:37:28 (GMT)
commitc06c61b28e8878da81a9b56f34c5570f3f3f747a (patch)
tree76f71209be2c8e9b03c7e2c8ae1cfc7612b3ad78 /win/tclWinLoad.c
parentf10d81b895d8ca9d30428aac9884685fb284986a (diff)
downloadtcl-c06c61b28e8878da81a9b56f34c5570f3f3f747a.zip
tcl-c06c61b28e8878da81a9b56f34c5570f3f3f747a.tar.gz
tcl-c06c61b28e8878da81a9b56f34c5570f3f3f747a.tar.bz2
Fix [Patch 2986105]: conditionally defining strcasecmp/strncasecmp
Fix gcc warning: comparison of unsigned expression >= 0 is always true
Diffstat (limited to 'win/tclWinLoad.c')
-rw-r--r--win/tclWinLoad.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/win/tclWinLoad.c b/win/tclWinLoad.c
index 606171d..f1eb1e0 100644
--- a/win/tclWinLoad.c
+++ b/win/tclWinLoad.c
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclWinLoad.c,v 1.27 2010/04/02 21:21:06 kennykb Exp $
+ * RCS: @(#) $Id: tclWinLoad.c,v 1.28 2010/04/13 13:37:29 nijtmans Exp $
*/
#include "tclWinInt.h"
@@ -305,14 +305,13 @@ TclpTempFileNameForLibrary(Tcl_Interp* interp, /* Tcl interpreter */
if (dllDirectoryName == NULL) {
Tcl_MutexLock(&loadMutex);
if (dllDirectoryName == NULL) {
- if ((nameLen = GetTempPathW(MAX_PATH, name)) >= 0) {
- if (nameLen >= MAX_PATH-12) {
- Tcl_SetErrno(ENAMETOOLONG);
- nameLen = 0;
- } else {
- wcscpy(name+nameLen, L"TCLXXXXXXXX");
- nameLen += 11;
- }
+ nameLen = GetTempPathW(MAX_PATH, name);
+ if (nameLen >= MAX_PATH-12) {
+ Tcl_SetErrno(ENAMETOOLONG);
+ nameLen = 0;
+ } else {
+ wcscpy(name+nameLen, L"TCLXXXXXXXX");
+ nameLen += 11;
}
status = 1;
if (nameLen != 0) {