diff options
author | dgp <dgp@users.sourceforge.net> | 2006-12-01 15:55:43 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2006-12-01 15:55:43 (GMT) |
commit | 986958b3d40c8667b6f7232cd0d7d7c6987014a6 (patch) | |
tree | e4a04cf8dde40fdd70f655a5519108dcd36b9f83 /doc | |
parent | 84e12e85c42e0e68ff5aa6b331aa0d53962f7c5a (diff) | |
download | tcl-986958b3d40c8667b6f7232cd0d7d7c6987014a6.zip tcl-986958b3d40c8667b6f7232cd0d7d7c6987014a6.tar.gz tcl-986958b3d40c8667b6f7232cd0d7d7c6987014a6.tar.bz2 |
TIP#287 IMPLEMENTATION
* doc/chan.n: New subcommand [chan pending].
* generic/tclBasic.c: Thanks to Michael Cleverly for proposal
* generic/tclInt.h: and implementation.
* generic/tclIOCmd.c:
* library/init.tcl:
* tests/chan.test:
* tests/ioCmd.test:
Diffstat (limited to 'doc')
-rw-r--r-- | doc/chan.n | 12 |
1 files changed, 11 insertions, 1 deletions
@@ -4,7 +4,7 @@ '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. '\" -'\" RCS: @(#) $Id: chan.n,v 1.6 2006/11/16 09:34:17 dkf Exp $ +'\" RCS: @(#) $Id: chan.n,v 1.7 2006/12/01 15:55:44 dgp Exp $ .so man.macros .TH chan n 8.5 Tcl "Tcl Built-In Commands" .BS @@ -493,6 +493,16 @@ Produces a list of all channel names. If \fIpattern\fR is specified, only those channel names that match it (according to the rules of \fBstring match\fR) will be returned. .TP +\fBchan pending \fImode channelId\fR +. +Depending on whether \fImode\fr is "input" or "output", returns the number of +bytes of input or output (respectively) currently buffered +internally for \fIchannelId\fr (especially useful in a readable event +callback to impose application-specific limits on input line lengths to avoid +a potential denial-of-service attack where a hostile user crafts +an extremely long line that exceeds the available memory to buffer it). +Returns -1 if the channel was not opened for the mode in question. +.TP \fBchan postevent \fIchannelId eventSpec\fR . This subcommand is used by command handlers specified with \fBchan |