sem_close man page on IRIX

Man page or keyword search:  
man Server   31559 pages
apropos Keyword Search (all sections)
Output format
IRIX logo
[printable version]



sem_close(3C)							 sem_close(3C)

NAME
     sem_close - close a posix named semaphore

SYNOPSIS
     #include <semaphore.h>
     int sem_close (sem_t *sem);

DESCRIPTION
     sem_close closes the connection to the named semaphore located at address
     sem.  The address sem may reside anywhere in the calling processes
     address space, but the process must have read and write access to sem.

     If multiple threads within a common process (i.e., sprocs, pthreads) are
     sharing sem, a single call to sem_close will close the named semaphore
     for all threads within the calling process.

     Once a named semaphore has been closed, subsequent operations on the
     semaphore by the calling process will fail until the semaphore has been
     reopened.

     If the calling process was the last process to close the semaphore, and
     the semaphore has been unlinked via sem_unlink, then the named semaphore
     will cease to exist.  Otherwise, the semaphore will persist.

     sem_close will fail if the following is true:

     [EINVAL]	    The semaphore located at address sem is not a valid posix
		    named semaphore.

SEE ALSO
     sem_destroy(3C), sem_init(3C), sem_getvalue(3C), sem_post(3C),
     sem_wait(3C), sem_trywait(3C), sem_open(3C), sem_unlink(3C),
     shm_open(3C), mmap(3C)

DIAGNOSTICS
     Upon successful completion, a value of 0 is returned to the calling
     process. Otherwise, a value of -1 is returned and errno is set to
     indicate the error.

									Page 1

[top]

List of man pages available for IRIX

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net