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

  man pages->HP-UX 11i man pages -> mq_unlink (2)              
Title
Content
Arch
Section
 

Contents


 mq_unlink(2)                                                   mq_unlink(2)




 NAME    [Toc]    [Back]
      mq_unlink - unlink a message queue

 SYNOPSIS    [Toc]    [Back]
      #include <sys/mqueue.h>

      int mq_unlink(const char *name);

 DESCRIPTION    [Toc]    [Back]
      The mq_unlink() system call disassociates the queue name, from a
      message queue specified by the argument, name.  After a successful
      call to mq_unlink(), attempts to open a message queue with the same
      name will fail, if the flag O_CREAT is not set in oflags.

      If there are no processes with existing open descriptors for the
      message queue, the queue is destroyed. If one or more processes have
      the message queue open, the removal of the queue is postponed until
      all descriptors for the queue have been closed.

      To use this function, link in the realtime library by specifying -lrt
      on the compiler or linker command line.

 RETURN VALUE    [Toc]    [Back]
      mq_unlink() returns the following values:

           0    Successful completion.

           -1   Failure, errno is set to indicate the error.

 ERRORS    [Toc]    [Back]
      If mq_unlink() fails, errno is set to one of the following values:

           [EACCES]       Permission to unlink the named message queue is
                          denied.

           [EINVAL]       The argument name is not a valid message queue
                          name.

           [ENAMETOOLONG] The length of the name string exceeds PATH_MAX
                          bytes, or the length of a (pathname) component of
                          the name string exceeds NAME_MAX bytes while
                          _POSIX_NO_TRUNC is in effect.

           [ENOENT]       The named message queue does not exist.

           [ENOSYS]       mq_unlink() is not supported by the
                          implementation.

 SEE ALSO    [Toc]    [Back]
      mq_open(2), mq_close(2).




 Hewlett-Packard Company            - 1 -      HP-UX 11i Version 2: Sep 2004






 mq_unlink(2)                                                   mq_unlink(2)




 STANDARDS CONFORMANCE    [Toc]    [Back]
      mq_unlink(): POSIX 1003.1b


 Hewlett-Packard Company            - 2 -      HP-UX 11i Version 2: Sep 2004
[ Back ]
      
      
 Similar pages
Name OS Title
mq_open Tru64 Establishes the connection between a message queue and a message queue descriptor (P1003.1b)
mq_receive Tru64 Receives the oldest, highest-priority message from the message queue (P1003.1b)
mq_send Tru64 Places a message in the message queue (P1003.1b)
mq_receive HP-UX receive a message from a message queue
msgrcv FreeBSD receive a message from a message queue
msgsnd FreeBSD send a message to a message queue
msgrcv Tru64 Receive a message from a message queue
msgsnd Tru64 Send a message to a message queue
mq_send HP-UX send a message to a message queue
msgsnd NetBSD send a message to a message queue
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service