*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->Tru64 Unix man pages -> msem_remove (3)              
Title
Content
Arch
Section
 

msem_remove(3)

Contents


NAME    [Toc]    [Back]

       msem_remove - Remove a semaphore

SYNOPSIS    [Toc]    [Back]

       #include <sys/mman.h>

       int msem_remove(
               msemaphore *sem );

LIBRARY    [Toc]    [Back]

       Standard C Library (libc)

PARAMETERS    [Toc]    [Back]

       Points  to  an  msemaphore  structure  which specifies the
       semaphore to be removed.

DESCRIPTION    [Toc]    [Back]

       The msem_remove() function  removes  a  binary  semaphore.
       Any  subsequent  use of the msemaphore structure before it
       is again initialized by calling the  msem_init()  function
       will have undefined results.

       The msem_remove() function also causes any process waiting
       in the msem_lock() function on the  removed  semaphore  to
       return with an error.

       If the msemaphore structure contains any value not resulting
 from a call to the msem_init() function followed by  a
       (possibly  empty) sequence of calls to the msem_lock() and
       msem_unlock() functions,  the  result  is  undefined.  The
       address of an msemaphore structure may be significant.  If
       the msemaphore structure contains any value copied from an
       msemaphore structure at a different address, the result is
       undefined.

NOTES    [Toc]    [Back]

       Trial use

RETURN VALUES    [Toc]    [Back]

       On  successful  completion,  the  msem_remove()   function
       returns  0  (zero).  On  error, the msem_remove() function
       returns -1 and sets errno to indicate the error.

ERRORS    [Toc]    [Back]

       If the msem_remove() function fails, errno may be  set  to
       the  following  value:  The  sem  parameter  points  to an
       msemaphore structure which specifies a semaphore which has
       been removed.

SEE ALSO    [Toc]    [Back]

      
      
       Functions:   msem_init(3),  msem_lock(3),  msem_unlock(3),
       munmap(2)



                                                   msem_remove(3)
[ Back ]
 Similar pages
Name OS Title
msem_remove HP-UX remove a semaphore in mapped file or anonymous region
ipcrm IRIX remove a message queue, semaphore set or shared memory id
ipcrm HP-UX remove a message queue, semaphore set, or shared memory identifier
ipcrm FreeBSD remove the specified message queues, semaphore sets, and shared segments
ipcrm OpenBSD remove the specified message queues, semaphore sets, and shared memory segments
pipcrm HP-UX remove a POSIX message queue or a POSIX named semaphore
sem_getvalue FreeBSD get the value of a semaphore
semget OpenBSD get semaphore set
sem_getvalue OpenBSD get the value of a semaphore
semget Linux get a semaphore set identifier
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service