diff options
| author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-06-19 09:25:51 (GMT) |
|---|---|---|
| committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2024-06-19 09:25:51 (GMT) |
| commit | 96dd069f9fc0b4e987db3a0ee7dde49edd93d3af (patch) | |
| tree | 6d6df6037727c460a921918e2c1f7c8d56ef61a4 /unix/tclUnixPipe.c | |
| parent | 5c6b7dbf18cbb7a2ecb9a064790d175411e9b066 (diff) | |
| parent | d064b77a41441825f6578546de36e0122cd344d0 (diff) | |
| download | tcl-96dd069f9fc0b4e987db3a0ee7dde49edd93d3af.zip tcl-96dd069f9fc0b4e987db3a0ee7dde49edd93d3af.tar.gz tcl-96dd069f9fc0b4e987db3a0ee7dde49edd93d3af.tar.bz2 | |
Merge trunk
Diffstat (limited to 'unix/tclUnixPipe.c')
| -rw-r--r-- | unix/tclUnixPipe.c | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/unix/tclUnixPipe.c b/unix/tclUnixPipe.c index ea1636e..a61c083 100644 --- a/unix/tclUnixPipe.c +++ b/unix/tclUnixPipe.c @@ -78,23 +78,23 @@ static int SetupStdFile(TclFile file, int type); */ static const Tcl_ChannelType pipeChannelType = { - "pipe", /* Type name. */ - TCL_CHANNEL_VERSION_5, /* v5 channel */ - NULL, /* Close proc. */ - PipeInputProc, /* Input proc. */ - PipeOutputProc, /* Output proc. */ - NULL, /* Seek proc. */ + "pipe", + TCL_CHANNEL_VERSION_5, + NULL, /* Deprecated. */ + PipeInputProc, + PipeOutputProc, + NULL, /* Deprecated. */ NULL, /* Set option proc. */ NULL, /* Get option proc. */ - PipeWatchProc, /* Initialize notifier. */ - PipeGetHandleProc, /* Get OS handles out of channel. */ - PipeClose2Proc, /* close2proc. */ - PipeBlockModeProc, /* Set blocking or non-blocking mode.*/ - NULL, /* flush proc. */ - NULL, /* handler proc. */ - NULL, /* wide seek proc */ - NULL, /* thread action proc */ - NULL /* truncation */ + PipeWatchProc, + PipeGetHandleProc, + PipeClose2Proc, + PipeBlockModeProc, + NULL, /* Flush proc. */ + NULL, /* Bubbled event handler proc. */ + NULL, /* Seek proc. */ + NULL, /* Thread action proc. */ + NULL /* Truncation proc. */ }; /* @@ -844,7 +844,7 @@ TclpCreateCommandChannel( * background exec). */ { char channelName[16 + TCL_INTEGER_SPACE]; - int channelId; + int fd; PipeState *statePtr = (PipeState *)Tcl_Alloc(sizeof(PipeState)); int mode; @@ -868,13 +868,13 @@ TclpCreateCommandChannel( */ if (readFile) { - channelId = GetFd(readFile); + fd = GetFd(readFile); } else if (writeFile) { - channelId = GetFd(writeFile); + fd = GetFd(writeFile); } else if (errorFile) { - channelId = GetFd(errorFile); + fd = GetFd(errorFile); } else { - channelId = 0; + fd = 0; } /* @@ -883,7 +883,7 @@ TclpCreateCommandChannel( * natural to use "pipe%d". */ - snprintf(channelName, sizeof(channelName), "file%d", channelId); + snprintf(channelName, sizeof(channelName), "file%d", fd); statePtr->channel = Tcl_CreateChannel(&pipeChannelType, channelName, statePtr, mode); return statePtr->channel; |
