copyfile(1tcl)


copyfile -- copy remainder of file1 to file2

Synopsis

copyfile [-bytes num|-maxbytes num] fromFileId toFileId

Description

Copies the rest of the file specified by fromFileId, starting from its current position, to the file specified by toFileId, starting from its current position.

If -bytes is specified, then num bytes are copied. If less than num bytes are available, an error is returned. If -maxbytes is specified, then num bytes are copied but no error is returned if less are available.

The command returns the number of bytes that were copied.

The -bytes option is particularly useful for mixing binary data in with ASCII commands or data in a data stream.


25 April 2004
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004