summaryrefslogtreecommitdiffstats
path: root/win/tclWinSerial.c
diff options
context:
space:
mode:
authormdejong <mdejong>2002-11-07 02:13:35 (GMT)
committermdejong <mdejong>2002-11-07 02:13:35 (GMT)
commit3e430e0f904e6835386a38276d1e7db4abe08e01 (patch)
treef86db515375673b4202dbd6719d7bd881da96117 /win/tclWinSerial.c
parentc8da171d49ce9c4601c168ee22fb991d7a0da3b5 (diff)
downloadtcl-3e430e0f904e6835386a38276d1e7db4abe08e01.zip
tcl-3e430e0f904e6835386a38276d1e7db4abe08e01.tar.gz
tcl-3e430e0f904e6835386a38276d1e7db4abe08e01.tar.bz2
* generic/tclEvent.c (TclInExit, TclInThreadExit):
Split out functionality of TclInExit to make it clear which one should be called in each situation. * generic/tclInt.decls: Declare TclInThreadExit. * generic/tclIntDecls.h: Regen. * generic/tclStubInit.c: Regen. * mac/tclMacChan.c (StdIOClose): * unix/tclUnixChan.c (FileCloseProc): * win/tclWinChan.c (FileCloseProc): * win/tclWinConsole.c (ConsoleCloseProc): * win/tclWinPipe.c (TclpCloseFile): * win/tclWinSerial.c (SerialCloseProc): Invoke the new TclInThreadExit method instead of TclInExit.
Diffstat (limited to 'win/tclWinSerial.c')
-rw-r--r--win/tclWinSerial.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/win/tclWinSerial.c b/win/tclWinSerial.c
index e5e69fa..a1cdcfd 100644
--- a/win/tclWinSerial.c
+++ b/win/tclWinSerial.c
@@ -11,7 +11,7 @@
*
* Serial functionality implemented by Rolf.Schroedter@dlr.de
*
- * RCS: @(#) $Id: tclWinSerial.c,v 1.21 2002/07/19 13:59:10 dkf Exp $
+ * RCS: @(#) $Id: tclWinSerial.c,v 1.22 2002/11/07 02:13:37 mdejong Exp $
*/
#include "tclWinInt.h"
@@ -632,11 +632,11 @@ SerialCloseProc(
/*
* Don't close the Win32 handle if the handle is a standard channel
- * during the exit process. Otherwise, one thread may kill the stdio
- * of another.
+ * during the thread exit process. Otherwise, one thread may kill
+ * the stdio of another.
*/
- if (!TclInExit()
+ if (!TclInThreadExit()
|| ((GetStdHandle(STD_INPUT_HANDLE) != serialPtr->handle)
&& (GetStdHandle(STD_OUTPUT_HANDLE) != serialPtr->handle)
&& (GetStdHandle(STD_ERROR_HANDLE) != serialPtr->handle))) {