SYNOPSIS
#include <semaphore.h>
int sem_post(sem_t *sem);
DESCRIPTION
The
When this operation results in a positive semaphore value, no threads were blocked waiting for the semaphore to be unlocked; the semaphore value is simply incremented.
When this operation results in a semaphore value of zero, one of the threads
waiting for the semaphore is allowed to return successfully from its
invocation of the
The
PARAMETERS
RETURN VALUES
When
EXAMPLES
None.
CONFORMANCE
UNIX 03. Derived from the POSIX Realtime Extension (1003.1b-1993/1003.1i-1995)
MULTITHREAD SAFETY LEVEL
MT-Safe.
PORTING ISSUES
On Windows, the waiting thread that is allowed to return is chosen by
the Win32
On UNIX platforms, this thread is chosen differently,
If the _POSIX_PRIORITY_SCHEDULING symbol is defined,
AVAILABILITY
MKS Toolkit for Professional Developers
MKS Toolkit for Enterprise Developers
MKS Toolkit for Enterprise Developers 64-Bit Edition
SEE ALSO
- Functions:
sem_trywait() ,sem_wait() ,semctl() ,semget() ,semop()
- Miscellaneous:
- semaphores
MKS Toolkit 9.2 Documentation Build 16.