summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2020-12-10 18:34:37 (GMT)
committerdgp <dgp@users.sourceforge.net>2020-12-10 18:34:37 (GMT)
commitb33993aaf9ec488a95bab79cd5dae16628ba0818 (patch)
treefe9e75c62b1d5a7ef2064caa0343164ecc9de3a0 /win
parent2f178f93ab97418ebc734320d8c9e2b309906bba (diff)
parentf4ec29ceb25d347536aee82060c3402bc87a94e8 (diff)
downloadtcl-b33993aaf9ec488a95bab79cd5dae16628ba0818.zip
tcl-b33993aaf9ec488a95bab79cd5dae16628ba0818.tar.gz
tcl-b33993aaf9ec488a95bab79cd5dae16628ba0818.tar.bz2
merge 8.6
Diffstat (limited to 'win')
-rw-r--r--win/rules.vc7
-rw-r--r--win/tclWinFile.c7
2 files changed, 8 insertions, 6 deletions
diff --git a/win/rules.vc b/win/rules.vc
index a0084a4..76d93cd 100644
--- a/win/rules.vc
+++ b/win/rules.vc
@@ -667,9 +667,10 @@ LINKERFLAGS = $(LINKERFLAGS) -ltcg
# MSVCRT - 1 -> link to dynamic C runtime even when building static Tcl build
# 0 -> link to static C runtime for static Tcl build.
# Does not impact shared Tcl builds (STATIC_BUILD == 0)
+# Default: 1 for Tcl 8.7 and up, 0 otherwise.
# TCL_USE_STATIC_PACKAGES - 1 -> statically link the registry and dde extensions
-# in the Tcl shell. 0 -> keep them as shared libraries
-# Does not impact shared Tcl builds.
+# in the Tcl and Wish shell. 0 -> keep them as shared libraries. Does
+# not impact shared Tcl builds. Implied by STATIC_BUILD since Tcl 8.7.
# USE_THREAD_ALLOC - 1 -> Use a shared global free pool for allocation.
# 0 -> Use the non-thread allocator.
# UNCHECKED - 1 -> when doing a debug build with symbols, use the release
@@ -724,7 +725,7 @@ MSVCRT = 0
!if [nmakehlp -f $(OPTS) "msvcrt"]
!message *** Doing msvcrt
!else
-!if $(STATIC_BUILD)
+!if "$(TCL_MAJOR_VERSION)" == "8" && "$(TCL_MINOR_VERSION)" < "7" && $(STATIC_BUILD)
MSVCRT = 0
!endif
!endif
diff --git a/win/tclWinFile.c b/win/tclWinFile.c
index 6cfeae1..2967cce 100644
--- a/win/tclWinFile.c
+++ b/win/tclWinFile.c
@@ -1250,7 +1250,7 @@ WinIsReserved(
if (path[4] == '\0') {
return 4;
- } else if (path [4] == ':' && path[5] == '\0') {
+ } else if (path[4] == ':' && path[5] == '\0') {
return 4;
}
} else if ((path[2] == 'n' || path[2] == 'N') && path[3] == '\0') {
@@ -1271,7 +1271,7 @@ WinIsReserved(
if (path[4] == '\0') {
return 4;
- } else if (path [4] == ':' && path[5] == '\0') {
+ } else if (path[4] == ':' && path[5] == '\0') {
return 4;
}
}
@@ -3100,7 +3100,8 @@ TclNativeCreateNativeRep(
goto done;
}
MultiByteToWideChar(CP_UTF8, MB_ERR_INVALID_CHARS, str, -1, nativePathPtr,
- len + 1);
+ len + 2);
+ nativePathPtr[len] = 0;
/*
* If path starts with "//?/" or "\\?\" (extended path), translate any