Guardian Procedure Calls Reference Manual (G06.25+)
Guardian Procedure Calls (L)
Guardian Procedure Calls Reference Manual—522629-013
8-18
LOCKINFO Procedure
(Superseded by FILE_GETLOCKINFO_ Procedure )
! (if LOCKLEN = 0)
END;
Definitions for the MISC word of the LIB structure (the remaining bits are reserved
for future use):
DEFINE
GENERIC^LOCK = MISC.<0>#; ! If set, record lock is a
! generic key lock
The number of LABINFO entries that can be returned to the caller of LOCKINFO
depends on the size of the LIB buffer (specified in the parameter
buffersize).
The structure LABINFO describes one lock “holder” or “waiter” of/for the locked
resource described by the above LIB structure. There are LIB.NUMLABS
occurrences of the LABINFO structure.
The detailed layout of LABINFO is described by the following example:
STRUCT LABINFO ( * );
BEGIN
INT
MISC, ! ID type, lock and grant state
! (see below)
USERID[ 0:3 ], ! Process ID or TRANSID (see below)
RESERVED; ! reserved for future use.
END;
Definitions for the MISC word of the LABINFO structure (the remaining bits are
reserved for future use):
DEFINE
IDTYPE = MISC.<0> #, ! If set: USERID is a process
! ID
GRANTSTATE = MISC.<1:3> #,! 0 = Waiting; 1 = Granted
INTENTFLAG = MISC.<4> #; ! Indicates the lock is an
! intent. (an intent is a lock
! internally established by
! DP2 to prevent interference
! from file lockers.)
•
Returned error codes
00 Information for one locked resource and all its accessors was returned
without error. More locks may exist; continue calling LOCKINFO.
01 End of lock information for
searchtype/searchid.
02 Invalid
searchtype (not 0, 1, 2, or 3).
11 Lock information for the file, process, or transaction in
searchid was not
found. If any information has been returned already, it is now invalid.
12 The lock tables in DP2 were changed between calls, so any previously
returned information may be invalid. To start over, set
ctlwds to zero and
call LOCKINFO again.