Open System Services System Calls Reference Manual (G06.29+, H06.08+, J06.03+)
SPT_FILE_OPEN_(2) OSS System Calls Reference Manual
• Used the Guardian OPEN procedure to open $RECEIVE.
Notification of this failure is not sent to the process reading $RECEIVE.
Opening an unconverted (C-series format) process from a high-PIN process
A high-PIN process cannot open an unconverted process unless the unconverted
process has the HIGHREQUESTERS object-file attribute set. If a high-PIN pro-
cess attempts to open a low-PIN process that does not have this attribute set, the
high-PIN process receives file-system error 560.
System Message
When a process is opened by either SPT_FILE_OPEN_() or the Guardian OPEN procedure, it
receives a process open message (unless it specified when opening $RECEIVE that it wants no
messages). This message is in D-series format (message -103) or in C-series format (message
-30), depending on what the receiving process specified when it opened $RECEIVE. This mes-
sage is also received if the backup process of a process pair performs an open. Therefore, a pro-
cess can expect two of these messages when being opened by a process pair.
You can obtain he process handle of the opener by a subsequent call to
FILE_GETRECEIVEINFO_. For a description of the process open message see the Guardian
Procedure Errors and Messages Manual.
DEFINE Considerations
• The filename or pathname parameter can be a DEFINE name; SPT_FILE_OPEN_()
uses the file name given by the DEFINE as the name of the object to be opened. If you
specify a CLASS TAPE DEFINE without the DEVICE attribute, the system selects the
tape drive to be opened. A CLASS TAPE DEFINE has other effects when supplied to
SPT_FILE_OPEN_(). For more information about DEFINEs, see Appendix E of the
Guardian Procedure Calls Reference Manual.
• If a supplied DEFINE name is a valid name but no such DEFINE exists, the procedure
returns an error 198 (missing DEFINE).
• When performing a backup open of a file originally opened with a DEFINE, filename
must contain the same DEFINE name. The DEFINE must exist and must have the same
value as when the primary open was performed.
Safeguard Considerations
For information on files protected by Safeguard, see the Safeguard Reference Manual.
OSS Considerations
• To open an OSS file by its pathname, set options bit 10 to 1 and specify the pathname
parameter.
• You can open OSS files only with shared exclusion mode.
EXAMPLES
The open in the following example has the following defaults: waited I/O, exclusion mode
(shared), access mode (read/write), sync depth (0).
error = SPT_FILE_OPEN_ ( filename, filenum );
RETURN VALUES
The SPT_FILE_OPEN_() function returns 0 (zero) upon successful completion. Otherwise,
this function returns a nonzero Guardian file-system error number that indicates the outcome of
the operation.
This function can return any error number that the Guardian FILE_OPEN_ procedure call can
return. It can also return the following error number:
7−202 Hewlett-Packard Company 527186-023