diff options
author | hobbs <hobbs@noemail.net> | 2000-09-06 18:46:13 (GMT) |
---|---|---|
committer | hobbs <hobbs@noemail.net> | 2000-09-06 18:46:13 (GMT) |
commit | 51d6172f23ef559ec7f303e6ba7a8d88f631b042 (patch) | |
tree | c3024605ec680290621a4399d0393442f3f8b20f /unix/tclUnixPipe.c | |
parent | bc90ed30426706dfe2cad63c1f9be2ccc58dd416 (diff) | |
download | tcl-51d6172f23ef559ec7f303e6ba7a8d88f631b042.zip tcl-51d6172f23ef559ec7f303e6ba7a8d88f631b042.tar.gz tcl-51d6172f23ef559ec7f303e6ba7a8d88f631b042.tar.bz2 |
* unix/tclUnixPipe.c (TclpCreateProcess): Removed WNOHANG from
Tcl_WaitPid call in error case of process creation on Unix, as it
would lead to defunct processes. [Bug: 6148]
FossilOrigin-Name: 4746499d46e6e013369d2911b6c7b74ceab383c6
Diffstat (limited to 'unix/tclUnixPipe.c')
-rw-r--r-- | unix/tclUnixPipe.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/unix/tclUnixPipe.c b/unix/tclUnixPipe.c index d234245..0b56333 100644 --- a/unix/tclUnixPipe.c +++ b/unix/tclUnixPipe.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclUnixPipe.c,v 1.9 2000/03/31 19:39:42 ericm Exp $ + * RCS: @(#) $Id: tclUnixPipe.c,v 1.10 2000/09/06 18:46:13 hobbs Exp $ */ #include "tclInt.h" @@ -444,10 +444,12 @@ TclpCreateProcess(interp, argc, argv, inputFile, outputFile, errorFile, if (pid != -1) { /* * Reap the child process now if an error occurred during its - * startup. + * startup. We don't call this with WNOHANG because that can lead to + * defunct processes on an MP system. We shouldn't have to worry + * about hanging here, since this is the error case. [Bug: 6148] */ - Tcl_WaitPid((Tcl_Pid) pid, &status, WNOHANG); + Tcl_WaitPid((Tcl_Pid) pid, &status, 0); } if (errPipeIn) { |