SRESET(2)
NAME
sreset − reset semaphore count
SYNOPSIS
int sreset(sem,count)
int sem;
int count;
DESCRIPTION
Sreset frees processes in the queue for semaphore sem, and resets its count to count. This corresponds to the operations of sdelete(sem) and sem=screate(count), except that it guarantees that the semaphore id sem does not change. Sreset returns SYSERR if sem is not a valid semaphore id. The current count in a semaphore does not affect resetting it.
SEE ALSO
scount(2), screate(2), sdelete(2), signal(2), wait(2)
December 01, 1986 — Xinu Programmer’s Manual