1SEM_UNLINK(3) Linux Programmer's Manual SEM_UNLINK(3)
2
3
4
6 sem_unlink - remove a named semaphore
7
9 #include <semaphore.h>
10
11 int sem_unlink(const char *name);
12
14 sem_unlink() removes the named semaphore referred to by sem. The sema‐
15 phore name is removed immediately. The semaphore is destroyed once all
16 other processes that have the semaphore open close it.
17
19 On success sem_unlink() returns 0; on error, -1 is returned, with errno
20 set to indicate the error.
21
23 EACCES The caller does not have permission to unlink this semaphore.
24
25 ENAMETOOLONG
26 name was too long.
27
28 ENOENT There is no semaphore with the given name.
29
31 POSIX.1-2001.
32
34 sem_getvalue(3), sem_open(3), sem_post(3), sem_wait(3), sem_overview(7)
35
36
37
38Linux 2.6.16 2006-03-25 SEM_UNLINK(3)