diff options
author | dgp <dgp@users.sourceforge.net> | 2014-05-31 02:40:00 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2014-05-31 02:40:00 (GMT) |
commit | 9b701fdae73c40aaff17354d1b5ec80aad5f6010 (patch) | |
tree | 8772939968bbf992cb7f11d20a0a235c7cd4c691 /unix/tclUnixPipe.c | |
parent | 3dcb02dc073df91fefb0d11006f1e9e3af8b9b4e (diff) | |
parent | 1f197f004a8ea114fe3cd6d3c8ec925200584e1c (diff) | |
download | tcl-9b701fdae73c40aaff17354d1b5ec80aad5f6010.zip tcl-9b701fdae73c40aaff17354d1b5ec80aad5f6010.tar.gz tcl-9b701fdae73c40aaff17354d1b5ec80aad5f6010.tar.bz2 |
Correct the interest masks in the Tcl_CreateFileHandler() calls in PipeWatchProc(). When we are interested in both readable and writable events of a command pipeline channel, we only want the readable from the read end of the pipe, and the writable from the write end of the pipe.
Diffstat (limited to 'unix/tclUnixPipe.c')
-rw-r--r-- | unix/tclUnixPipe.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/unix/tclUnixPipe.c b/unix/tclUnixPipe.c index 9c21b28..a02044e 100644 --- a/unix/tclUnixPipe.c +++ b/unix/tclUnixPipe.c @@ -1143,7 +1143,7 @@ PipeWatchProc( if (psPtr->inFile) { newmask = mask & (TCL_READABLE | TCL_EXCEPTION); if (newmask) { - Tcl_CreateFileHandler(GetFd(psPtr->inFile), mask, + Tcl_CreateFileHandler(GetFd(psPtr->inFile), newmask, (Tcl_FileProc *) Tcl_NotifyChannel, psPtr->channel); } else { Tcl_DeleteFileHandler(GetFd(psPtr->inFile)); @@ -1152,7 +1152,7 @@ PipeWatchProc( if (psPtr->outFile) { newmask = mask & (TCL_WRITABLE | TCL_EXCEPTION); if (newmask) { - Tcl_CreateFileHandler(GetFd(psPtr->outFile), mask, + Tcl_CreateFileHandler(GetFd(psPtr->outFile), newmask, (Tcl_FileProc *) Tcl_NotifyChannel, psPtr->channel); } else { Tcl_DeleteFileHandler(GetFd(psPtr->outFile)); |