fix some semaphore wait semantics (race condition deadlock and error checking)
[musl] / src / thread / sem_post.c
2011-03-04 Rich Felkerimplement POSIX semaphores