lock_set_destroy


Function - Destroy a lock set and its associated locks.

SYNOPSIS

kern_return_t   lock_set_destroy
                (task_t                                    task,
                 lock_set_t                            lock_set);

PARAMETERS

task
The task associated with the lock set.

lock_set
[in send right] The port naming the lock set being destroyed.

DESCRIPTION

The lock_set_destroy function will destroy a lock set and all of its associated locks. Threads that are blocked on locks represented by the destroyed lock set are unblocked and will receive a KERN_LOCK_SET_DESTROYED error message indicating that the lock set was destroyed. The lock_set_destroy function will only succeed if the specified task is associated with the specified lock set.

RETURN VALUES

KERN_INVALID_ARGUMENT
The specified lock set or task is invalid.

KERN_INVALID_RIGHT
The specified task does not own the specified lock set.

KERN_LOCK_SET_DESTROYED
The specified lock set does not exist.

KERN_SUCCESS
The lock set was destroyed.

RELATED INFORMATION

Functions: lock_acquire, lock_make_stable, lock_try, lock_handoff, lock_handoff_accept, lock_try, lock_set_create.