sem_unlink(3P4)
NAME
sem_unlink − remove counting semaphore name
SYNOPSIS
#include <semaphore.h>
int sem_unlink(name)
char ∗name;
DESCRIPTION
The sem_unlink function removes the name of the counting semaphore name. If the semaphore is currently referenced by other processes, then sem_unlink will have no effect on the state of the semaphore. If one or more processes refer to the counting semaphore at the time sem_unlink is called, removal of the semaphore is postponed until the last reference to the semaphore is removed by a call to sem_destroy.
RETURN VALUE
Upon successful completion, the sem_unlink function returns a zero. If any of the following conditions occur, the sem_unlink function will return -1 and set errno to the corresponding value:
[EINVAL] The argument name does not refer to a valid counting semaphore.
FILES
/usr/lib/libposix4.a
SEE ALSO
sem_destroy(3P4), sem_lock(3P4), sem_init(3P4), sem_unlock(3P4), sem_trylock(3P4).
WARNING
The interface to sem_unlink is based on IEEE Draft Standard P1003.4/D12. This is an unapproved draft, subject to change. Use of information contained in this unapproved draft is at your own risk. This interface will change to reflect any changes made by future drafts of POSIX 1003.4.
CX/UX Programmer’s Reference Manual