Version 4 of chan truncate

Updated 2014-12-01 14:54:59 by dkf

Truncate the file behind the given channel at the given location (or the current by default). Operation is (probably) not supported by non-file channels.

chan truncate channelId ?length?

Like the ftruncate() call in C's stdio.

Introduced in Tcl 8.5.


AMG: For one possible use of this command, see How do I remove one line from a file?.