summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
Diffstat (limited to 'win')
-rw-r--r--win/Makefile.in2
-rw-r--r--win/tclWinChan.c4
-rw-r--r--win/tclWinConsole.c2
-rw-r--r--win/tclWinPipe.c2
-rw-r--r--win/tclWinPort.h3
-rw-r--r--win/tclWinSerial.c2
-rw-r--r--win/tclWinSock.c7
7 files changed, 15 insertions, 7 deletions
diff --git a/win/Makefile.in b/win/Makefile.in
index 7bfe028..0035a50 100644
--- a/win/Makefile.in
+++ b/win/Makefile.in
@@ -995,7 +995,7 @@ clean: cleanhelp clean-packages
distclean: distclean-packages clean
$(RM) Makefile config.status config.cache config.log tclConfig.sh \
- config.status.lineno tclsh.exe.manifest
+ config.status.lineno tclsh.exe.manifest tclUuid.h
#
# Bundled package targets
diff --git a/win/tclWinChan.c b/win/tclWinChan.c
index 62991fc..166636c 100644
--- a/win/tclWinChan.c
+++ b/win/tclWinChan.c
@@ -1325,7 +1325,7 @@ TclpGetDefaultStdChannel(
*/
if (Tcl_SetChannelOption(NULL,channel,"-translation","auto")!=TCL_OK ||
- Tcl_SetChannelOption(NULL,channel,"-eofchar","\032 {}")!=TCL_OK ||
+ Tcl_SetChannelOption(NULL,channel,"-eofchar","\x1A {}")!=TCL_OK ||
Tcl_SetChannelOption(NULL,channel,"-buffering",bufMode)!=TCL_OK) {
Tcl_Close(NULL, channel);
return (Tcl_Channel) NULL;
@@ -1402,7 +1402,7 @@ TclWinOpenFileChannel(
*/
Tcl_SetChannelOption(NULL, infoPtr->channel, "-translation", "auto");
- Tcl_SetChannelOption(NULL, infoPtr->channel, "-eofchar", "\032 {}");
+ Tcl_SetChannelOption(NULL, infoPtr->channel, "-eofchar", "\x1A {}");
return infoPtr->channel;
}
diff --git a/win/tclWinConsole.c b/win/tclWinConsole.c
index 753a572..6688ab1 100644
--- a/win/tclWinConsole.c
+++ b/win/tclWinConsole.c
@@ -2199,7 +2199,7 @@ TclWinOpenConsoleChannel(
*/
Tcl_SetChannelOption(NULL, chanInfoPtr->channel, "-translation", "auto");
- Tcl_SetChannelOption(NULL, chanInfoPtr->channel, "-eofchar", "\032 {}");
+ Tcl_SetChannelOption(NULL, chanInfoPtr->channel, "-eofchar", "\x1A {}");
Tcl_SetChannelOption(NULL, chanInfoPtr->channel, "-encoding", "utf-16");
return chanInfoPtr->channel;
}
diff --git a/win/tclWinPipe.c b/win/tclWinPipe.c
index 4a39e8c..4a84038 100644
--- a/win/tclWinPipe.c
+++ b/win/tclWinPipe.c
@@ -1833,7 +1833,7 @@ TclpCreateCommandChannel(
*/
Tcl_SetChannelOption(NULL, infoPtr->channel, "-translation", "auto");
- Tcl_SetChannelOption(NULL, infoPtr->channel, "-eofchar", "\032 {}");
+ Tcl_SetChannelOption(NULL, infoPtr->channel, "-eofchar", "\x1A {}");
return infoPtr->channel;
}
diff --git a/win/tclWinPort.h b/win/tclWinPort.h
index b61e481..d7d60a4 100644
--- a/win/tclWinPort.h
+++ b/win/tclWinPort.h
@@ -461,6 +461,9 @@ typedef DWORD_PTR * PDWORD_PTR;
# pragma warning(disable:4090) /* see: https://developercommunity.visualstudio.com/t/c-compiler-incorrect-propagation-of-const-qualifie/390711 */
# pragma warning(disable:4146)
# pragma warning(disable:4244)
+#if !defined(_WIN64)
+# pragma warning(disable:4305)
+#endif
# pragma warning(disable:4267)
# pragma warning(disable:4996)
#endif
diff --git a/win/tclWinSerial.c b/win/tclWinSerial.c
index f087d70..449a8d7 100644
--- a/win/tclWinSerial.c
+++ b/win/tclWinSerial.c
@@ -1514,7 +1514,7 @@ TclWinOpenSerialChannel(
*/
Tcl_SetChannelOption(NULL, infoPtr->channel, "-translation", "auto");
- Tcl_SetChannelOption(NULL, infoPtr->channel, "-eofchar", "\032 {}");
+ Tcl_SetChannelOption(NULL, infoPtr->channel, "-eofchar", "\x1A {}");
return infoPtr->channel;
}
diff --git a/win/tclWinSock.c b/win/tclWinSock.c
index 3980006..9ac1a15 100644
--- a/win/tclWinSock.c
+++ b/win/tclWinSock.c
@@ -2154,6 +2154,8 @@ Tcl_OpenTcpServerEx(
const char *service, /* Port number to open. */
const char *myHost, /* Name of local host. */
unsigned int flags, /* Flags. */
+ int backlog, /* Length of OS listen backlog queue, or -1
+ * for default. */
Tcl_TcpAcceptProc *acceptProc,
/* Callback for accepting connections from new
* clients. */
@@ -2276,7 +2278,10 @@ Tcl_OpenTcpServerEx(
* different, and there may be differences between TCP/IP stacks).
*/
- if (listen(sock, SOMAXCONN) == SOCKET_ERROR) {
+ if (backlog < 0) {
+ backlog = SOMAXCONN;
+ }
+ if (listen(sock, backlog) == SOCKET_ERROR) {
Tcl_WinConvertError((DWORD) WSAGetLastError());
closesocket(sock);
continue;