Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ sem_close(3) — OSF/1 X2.0-8 MIPS

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

sem_mksem(3)

sem_open(3)

sem_close(3)  —  Subroutines

Digital

NAME

sem_close − Deallocate the specified binary semaphore set descriptor (P1003.4/D11)

SYNOPSIS

#include <binsem.h>

int sem_close (
binsemset_t binsemdes) ;

PARAMETERS

binsemdes The binary semaphore set descriptor. 

DESCRIPTION

The sem_close function makes a binary semaphore set descriptor available for reuse by deallocating the binary semaphore set descriptor indicated by the binsemdes argument. 

When you close the last semaphore reference, the current state of the binary semaphores in the set persists.  A subsequent call to the sem_open function reopens the binary semaphore set. 

RETURN VALUES

On a successful call, a value of 0 is returned. Otherwise, a value of −1 is returned and errno is set to indicate that an error occurred. 

ERRORS

The sem_close function fails under the following conditions:

[EINVAL] The binsemdes argument is not a valid binary semaphore set descriptor. 

[ENOSYS] The function sem_close is not supported by this implementation. 

RELATED INFORMATION

Functions: sem_mksem(3), sem_open(3)

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