### datUnlock

Unlock an object so that it can be locked by a different thread

#### Description:

This function removes a lock on the supplied HDS object. An error is reported if the object is not locked by the current thread. If " recurs" is non-zero, an error will be reported if any child component within the supplied object is not locked by the current thread. See datLock.

The object must be locked again, using datLock, before it can be used by any other HDS function. All objects are initially locked by the current thread when they are created.

#### Invocation

datUnlock( HDSLoc $\ast$locator, int recurs, int $\ast$status );

#### Arguments

##### locator = HDSLoc $\ast$ (Given)
Locator to the object that is to be unlocked.
##### recurs = int (Given)
If the supplied object is unlocked successfully, and " recurs" is non-zero, then an attempt is made to unlock any component objects contained within the supplied object.
##### status = int$\ast$ (Given and Returned)
Pointer to global status.

#### Notes:

• The majority of HDS functions will report an error if the object supplied to the function has not been locked for use by the calling thread. The exceptions are the functions datLock and datLocked.