Guardian Procedure Calls Reference Manual (G06.25+)

Guardian Procedure Calls (O)
Guardian Procedure Calls Reference Manual522629-013
11-43
OPENEDIT_ Procedure
-2 Page-table tags are out of order.
-3 Page-table tag is outside legal range.
-4 Page-table block number is outside of file.
-5 Page table has duplicate block numbers.
11 File does not exist; indicates that the file does not exist and that the
access
parameter indicates read-only access to the file.
14 Device does not exist; indicates that the device-name part of the file name
designates a device that either does not exist or is not a disk device.
16 File has not been opened, wrong file type; indicates that the file is not an EDIT
file (that is, the file type is not unstructured or the file code is not 101 or 102).
31 Unable to obtain buffer space; indicates that the file’s directory does not fit into
IOEdit’s extended data segment and OPENEDIT_ is unable to enlarge the
segment.
34 Unable to obtain memory space for control block; indicates that the number of
IOEdit files already open is equal to the maximum number specified or
assumed when INITIALIZEEDIT was called.
59 File is bad; indicates that the file exists and has the correct file type and file
code for an EDIT file, but the data in the file has an incorrect format and
OPENEDIT_ is unable to repair it.
The negative values listed above indicate that OPENEDIT_ has found a format
error in the file that it can probably correct. At the time that one of these values is
returned, the file has not yet been altered. If you immediately call CLOSEEDIT_ or
CLOSEEDIT, the file is closed without change. If instead you call another IOEdit
procedure, IOEdit tries to correct the format of the file. The format corrections are
written to disk when CLOSEEDIT_ or CLOSEEDIT is finally called. If IOEdit fails to
correct the format error, error 59 is returned for all subsequent IOEdit operations
on the file.
file-name:length input:input
STRING .EXT:ref:*, INT:value
specifies the name of the file to be opened. If the file must be created, this name is
assigned to it. The value of
file-name must be exactly length bytes long and
must be a valid file name or DEFINE name. If the name is partially qualified, it is
resolved using the contents of the =_DEFAULTS DEFINE.
filenum input, output
INT:ref:1
on input, if the specified value is greater than or equal to 0 and if the file
designated by
file-name exists, indicates that the caller has already opened the
file through the file system and that
filenum is the number returned by the file
system to identify the open file. In this case, OPENEDIT_ only verifies that the file
is an EDIT file and creates the internal data structures necessary for subsequent
IOEdit operations on the file. If
filenum is a negative value or if the file does not
exist, OPENEDIT_ opens the file by calling FILE_OPEN_ (after calling