From a3ffa1319a78d7f38aacc6fc7d885a2f7d23e0df Mon Sep 17 00:00:00 2001 From: davygrvy Date: Wed, 27 Nov 2002 22:57:06 +0000 Subject: * win/tclWinChan.c (Tcl_MakeFileChannel): return of DuplicateHandle() incorrectly used [Bug 618852]. --- ChangeLog | 3 +++ win/tclWinChan.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 595bb99..156d329 100644 --- a/ChangeLog +++ b/ChangeLog @@ -11,6 +11,9 @@ * win/tclWinSock.c: WSAStartup() loaded version comparison error which resulted in 2.0 looking less than 1.1. + * win/tclWinChan.c (Tcl_MakeFileChannel): return of + DuplicateHandle() incorrectly used [Bug 618852]. + 2002-11-26 Jeff Hobbs * generic/tclEncoding.c (TclFinalizeEncodingSubsystem): properly diff --git a/win/tclWinChan.c b/win/tclWinChan.c index 1a4c4ec..e6b61b3 100644 --- a/win/tclWinChan.c +++ b/win/tclWinChan.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: tclWinChan.c,v 1.25 2002/11/07 02:13:37 mdejong Exp $ + * RCS: @(#) $Id: tclWinChan.c,v 1.26 2002/11/27 22:57:18 davygrvy Exp $ */ #include "tclWinInt.h" @@ -1034,7 +1034,7 @@ Tcl_MakeFileChannel(rawHandle, mode) GetCurrentProcess(), &dupedHandle, 0, FALSE, DUPLICATE_SAME_ACCESS); - if (result != 0) { + if (result == 0) { /* * Unable to make a duplicate. It's definately invalid at this * point. -- cgit v0.12