Contents

os_unfair_lock_assert_owner

Triggers an assertion if the calling thread doesn’t own the specified unfair lock.

Declaration

extern void os_unfair_lock_assert_owner(const os_unfair_lock *lock);

Parameters

  • lock:

    A pointer to the unfair lock to check.

Discussion

If the calling thread owns the specified lock, this function returns normally. If the lock is unlocked or owned by a different thread, this function asserts and terminates the process.

See Also

Unfair Locking