Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ sem_destroy(3R) — SunOS 5.3

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

sem_init(3R)

sem_open(3R)

sem_destroy(3R)

NAME

sem_destroy − destroy an unnamed semaphore

SYNOPSIS

cc [ flag ... ] file ... −lposix4 [ library ... ]

#include <semaphore.h>

int sem_destroy(sem_t ∗sem);

typedef struct {
...
} sem_t; /∗opaque POSIX.4 semaphore∗/

MT-LEVEL

MT-Safe

DESCRIPTION

sem_destroy() is used to destroy the unnamed semaphore, sem, which was initialized by sem_init(3R). 

RETURN VALUES

If successful, sem_destroy() returns 0, otherwise it returns -1 and sets errno to indicate the error condition. 

ERRORS

EINVAL sem is not a valid semaphore. 

ENOSYS sem_destroy() is not supported by this implementation. 

EBUSY Other processes (or LWPs or threads) are currently blocked on the semaphore. 

SEE ALSO

sem_init(3R), sem_open(3R)

Sun Microsystems  —  Last change: 12 Aug 1993

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026