diff options
author | bch <brad.harder@gmail.com> | 2015-02-08 05:04:33 (GMT) |
---|---|---|
committer | bch <brad.harder@gmail.com> | 2015-02-08 05:04:33 (GMT) |
commit | 4214c7a3a945dc09ed6023d87a28a2a0f85e1157 (patch) | |
tree | 0930698a8ac1bba17ef96f99d0cebaa2a4d61b8b /generic | |
parent | 02cc7437b244b37fbba3c278abf9835c6bd7109a (diff) | |
download | tcl-4214c7a3a945dc09ed6023d87a28a2a0f85e1157.zip tcl-4214c7a3a945dc09ed6023d87a28a2a0f85e1157.tar.gz tcl-4214c7a3a945dc09ed6023d87a28a2a0f85e1157.tar.bz2 |
inputProc and outputProc tests run conditionally on TCL_READABLE, TCL_WRITABLE mask
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclIO.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/generic/tclIO.c b/generic/tclIO.c index 702e2a0..0ba864a 100644 --- a/generic/tclIO.c +++ b/generic/tclIO.c @@ -1551,10 +1551,10 @@ Tcl_CreateChannel( if (NULL == typePtr->closeProc) Tcl_Panic("Required closeProc is unset."); - if (NULL == typePtr->inputProc) + if ((TCL_READABLE & mask) && (NULL == typePtr->inputProc)) Tcl_Panic("Required inputProc is unset."); - if (NULL == typePtr->outputProc) + if ((TCL_WRITABLE & mask) && (NULL == typePtr->outputProc)) Tcl_Panic("Required outputProc is unset."); if (NULL == typePtr->watchProc) |