IOS_$TRUNCATE Domain/OS IOS_$TRUNCATE
NAME
ios_$truncate - truncate an object at the current stream marker
SYNOPSIS (C)
#include <apollo/base.h>
#include <apollo/ios.h>
void ios_$truncate(
ios_$id_t &stream_id,
status_$t *status)
SYNOPSIS (Pascal)
%include '/sys/ins/base.ins.pas';
%include '/sys/ins/ios.ins.pas';
procedure ios_$truncate(
in stream_id: ios_$id_t;
out status: status_$t);
SYNOPSIS (FORTRAN)
%include '/sys/ins/base.ins.ftn'
%include '/sys/ins/ios.ins.ftn'
integer*2 stream_id
integer*4 status
call ios_$truncate(stream_id, status)
DESCRIPTION
Ios_$truncate sets the value of the object's length attribute to match
the stream marker. (Writing data to a stream that lengthens the object
implicitly increases the length attribute's value.) This call sets the
end of the object (EOF) to the stream marker, effectively deleting any
data in the object past the stream marker. If the stream marker is
already at EOF, ios_$truncate has no effect. Truncating an object does
not close the stream open to it.
stream_id
The ID of a stream on which the object is open.
status
The completion status.
SEE ALSO
ios_$inq_file_attr.