summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2018-10-05 19:40:55 (GMT)
committerdgp <dgp@users.sourceforge.net>2018-10-05 19:40:55 (GMT)
commite13c5f55a1b87cdf7eb3f5da7bb71ac0747ee6e0 (patch)
tree2e9220f97973f861a76443fbb2f4219abe550444
parentc74364be4c0ab1ca34ba34f02a662708473d62a9 (diff)
parent85aac3aef7c9fa70dc07467858439a6d6f533ac0 (diff)
downloadtcl-e13c5f55a1b87cdf7eb3f5da7bb71ac0747ee6e0.zip
tcl-e13c5f55a1b87cdf7eb3f5da7bb71ac0747ee6e0.tar.gz
tcl-e13c5f55a1b87cdf7eb3f5da7bb71ac0747ee6e0.tar.bz2
merge 8.6
-rw-r--r--win/tclWinFCmd.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/win/tclWinFCmd.c b/win/tclWinFCmd.c
index 52ea8c6..2f28154 100644
--- a/win/tclWinFCmd.c
+++ b/win/tclWinFCmd.c
@@ -1026,7 +1026,8 @@ DoRemoveJustDirectory(
if (nativePath == NULL || nativePath[0] == '\0') {
Tcl_SetErrno(ENOENT);
- goto end;
+ Tcl_DStringInit(errorPtr);
+ return TCL_ERROR;
}
attr = GetFileAttributes(nativePath);
@@ -1108,9 +1109,7 @@ DoRemoveJustDirectory(
end:
if (errorPtr != NULL) {
- char *p;
- Tcl_WinTCharToUtf(nativePath, -1, errorPtr);
- p = Tcl_DStringValue(errorPtr);
+ char *p = Tcl_WinTCharToUtf(nativePath, -1, errorPtr);
for (; *p; ++p) {
if (*p == '\\') *p = '/';
}