Contents

IOLockTryLock

Declaration

bool IOLockTryLock(struct IOLock *lock);

Parameters

  • lock:

    Pointer to the allocated lock.

Return Value

True if the mutex was unlocked and is now locked by the caller, otherwise false.

Discussion

Attempt to lock a mutex.

Lock the mutex if it is currently unlocked, and return true. If the lock is held by any thread, return false.

See Also

Functions