The
mq_unlink()
function removes the message queue named by the string
name.
If one or more processes have the message queue open when
mq_unlink()
is called, destruction of the message queue will be postponed
until all references to the message queue have been closed.
However, the
mq_unlink()
call need not block until all references have been closed; it may return
immediately.
After a successful call to
mq_unlink(),
reuse of the name will subsequently cause
mq_open(2)
to behave as if no message queue of this name exists.