summaryrefslogtreecommitdiffstats
path: root/win/tclWinFCmd.c
diff options
context:
space:
mode:
authornijtmans <nijtmans>2010-08-30 09:19:37 (GMT)
committernijtmans <nijtmans>2010-08-30 09:19:37 (GMT)
commitaf6af80ab88abd5db88a9b378434fa041f19a74a (patch)
tree0d954c81b8cc7292bf263a114bf84176c178bbe1 /win/tclWinFCmd.c
parentff9209620e3750a879b1cfe363cb06042092dfdc (diff)
downloadtcl-af6af80ab88abd5db88a9b378434fa041f19a74a.zip
tcl-af6af80ab88abd5db88a9b378434fa041f19a74a.tar.gz
tcl-af6af80ab88abd5db88a9b378434fa041f19a74a.tar.bz2
[Freq 2965056]: Windows build with -DUNICODE
Diffstat (limited to 'win/tclWinFCmd.c')
-rw-r--r--win/tclWinFCmd.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/win/tclWinFCmd.c b/win/tclWinFCmd.c
index fd5cd5d..7853227 100644
--- a/win/tclWinFCmd.c
+++ b/win/tclWinFCmd.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: tclWinFCmd.c,v 1.63 2010/08/14 17:13:02 nijtmans Exp $
+ * RCS: @(#) $Id: tclWinFCmd.c,v 1.64 2010/08/30 09:19:38 nijtmans Exp $
*/
#include "tclWinInt.h"
@@ -328,8 +328,8 @@ DoRenameFile(
TCHAR *nativeSrcRest, *nativeDstRest;
const char **srcArgv, **dstArgv;
int size, srcArgc, dstArgc;
- TCHAR nativeSrcPath[MAX_PATH*2];
- TCHAR nativeDstPath[MAX_PATH*2];
+ TCHAR nativeSrcPath[MAX_PATH];
+ TCHAR nativeDstPath[MAX_PATH];
Tcl_DString srcString, dstString;
const char *src, *dst;
@@ -465,7 +465,7 @@ DoRenameFile(
TCHAR *nativeRest, *nativeTmp, *nativePrefix;
int result, size;
- TCHAR tempBuf[MAX_PATH*2];
+ TCHAR tempBuf[MAX_PATH];
size = tclWinProcs->getFullPathNameProc(nativeDst, MAX_PATH,
tempBuf, &nativeRest);
@@ -473,8 +473,7 @@ DoRenameFile(
return TCL_ERROR;
}
nativeTmp = (TCHAR *) tempBuf;
- ((char *) nativeRest)[0] = '\0';
- ((char *) nativeRest)[1] = '\0'; /* In case it's Unicode. */
+ nativeRest[0] = '\0';
result = TCL_ERROR;
nativePrefix = (tclWinProcs->useWide)