summaryrefslogtreecommitdiff
path: root/src/thread/sem_open.c
AgeCommit message (Collapse)AuthorLines
2011-03-10fix failure behavior of sem_open when sem does not existRich Felker-1/+5
2011-03-10fix sem_open and sem_close to obey posix semanticsRich Felker-26/+80
multiple opens of the same named semaphore must return the same pointer, and only the last close can unmap it. thus the ugly global state keeping track of mappings. the maximum number of distinct named semaphores that can be opened is limited sufficiently small that the linear searches take trivial time, especially compared to the syscall overhead of these functions.
2011-03-04implement POSIX semaphoresRich Felker-0/+116