Guardian Procedure Calls Reference Manual (G06.25+)

Guardian Procedure Calls (C)
Guardian Procedure Calls Reference Manual522629-013
3-134
CONTROL Procedure
Considerations
Nowait and CONTROL
If the CONTROL procedure is used on a file that is opened nowait, it must be
completed with a call to the AWAITIO procedure.
Disk files
Writing EOF to an unstructured file
Writing EOF to an unstructured disk file sets the EOF pointer to the relative
byte address indicated by the setting of the next-record pointer and writes the
new EOF setting in the file label on disk. Specifically, write:
end-of-file pointer := next-record pointer;
(File pointer action for CONTROL operation 2, write EOF.)
File is locked
If a CONTROL operation is attempted for a file locked through a
filenum
other than that specified in the call to CONTROL, the call is rejected with a “file
is locked” error 73.
If any record is locked in a file, a call to CONTROL to write EOF (operation 2)
to that same file will be rejected with a “file is locked” error 73.
Magnetic tapes
When device is not ready
If a magnetic tape rewind is performed concurrently with application program
execution (that is, rewind operation <> 6), any attempt to perform a read, write,
or control operation to the rewinding tape unit while rewind is taking place
results in an error indication. A subsequent call to FILE_GETINFO_ or
FILEINFO shows that an error 100 occurred.
Wait for rewind to complete
If a magnetic tape rewind operation = 6 (wait for completion) is performed as a
nowait operation, the application waits at the call to AWAITIO for the rewind to
complete.