Guardian Procedure Calls Reference Manual (G06.25+)
Guardian Procedure Calls (F)
Guardian Procedure Calls Reference Manual—522629-013
5-99
FILE_GETLOCKINFO_ Procedure
The information is returned in the following format:
[0] Lock type. 0 indicates a file lock; 1 indicates a record lock.
[1] Flags. The bits are:
<0> = 1 Indicates a generic lock
<1:15> (reserved)
[2] The number of participants (the number of holders and waiters for the
lock).
[3:4] Record specifier (4 bytes) if the lock is a record lock on a Format 1 file
that is not key-sequenced; undefined otherwise.
[5] The length in bytes of the key if the lock is a record lock on either a
key-sequenced file or a Format 2 non-key-sequenced file (the length is
always 8 in the latter case); 0 otherwise.
[6:N] The key value if the lock is a record lock on a key-sequenced file, or a
Record specifier (8 bytes) if the lock is a record lock on a Format 2
non-key-sequenced file.
lock-descr-length input
INT:value
specifies the length in bytes of the buffer pointed to by
lock-descr.
participants output
INT .EXT:ref:*
returns an array in which each entry describes a process or transaction that is
holding or waiting for the lock described by
lock-descr. The maximum number
of processes or transactions that can be described is specified by
max-
participants. Each entry is 12 words long and has the following format:
[0] Flags. The bits have the following meanings:
<0> = 1 The participant is identified by process handle.
0 The participant is identified by transid.
<1:3> = 1 The lock is granted.
0 The lock is in the waiting state.
<4> = 1 The lock is an intent lock internally set by DP2.
<5:15> (Reserved)
[1] Reserved
[2:11] The process handle of the participant
(if
participants[0].<0> =1).