![]() |
FSSetForkSize |
||||
Header: | Files.h | Carbon status: | Supported | |
Changes the size of an open fork.
OSErr FSSetForkSize ( SInt16 forkRefNum, UInt16 positionMode, SInt64 positionOffset );
The reference number of the fork
The base location for the new size
The offset of the new size from the base
A result code. If there is not enough space on the volume to extend the fork, then dskFulErr is returned and the forks size is unchanged.
The logical end-of-file will be set to the position indicated by the positionMode and positionOffset parameters.
The forks new size may be less than, equal to, or greater than the forks current size. If the forks new size is greater than the forks current size, then the additional bytes (between the old and new size) will have an undetermined value.
If the forks current position is larger than the forks new size, then the current position will be set to the new fork size. That is, the current position will be equal to the logical end of file.
Supported in Carbon. Available in Carbon 1.0.2 and later when running Mac OS 9, or later.
© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)