mq_close - Closes a message queue (P1003.1b)
#include <mqueue.h>
int mq_close ( mqd_t mqdes);
Realtime Library (librt.so, librt.a)
Specifies a message queue descriptor.
The mq_close function closes a message queue. This function
removes the association between the message queue
descriptor, mqdes, and its open message queue description.
When all message queue descriptors associated with an open
message queue description have been closed, the associated
open message queue description is removed. The message
associated with the message queue will then be deleted if
mq_unlink was already called, or is called after all processes
have closed the queue.
On successful completion, the function returns the value 0
(zero); otherwise, the function returns the value -1 and
sets errno to indicate the error.
The mq_close function fails under the following conditions:
The mqdes argument is an invalid message queue
descriptor. An internal virtual memory error occurred.
Functions: mq_open(3), mq_unlink(3)
Guide to Realtime Programming
mq_close(3)
[ Back ] |