I have an application which uses message queues. I sometimes get an error message when trying to post a message on the queue.
The error is EINVAL. According to the documentation on this system call,
the meaning is as follows.
EINVAL
One of the following cases is true:
msg_len was negative
msg_prio was greater than MQ_PRIO_MAX
msg_prio was less than 0
the MQ_PRIO_RESTRICT flag was set in the mq_attr member of mqdes, and msg_prio was greater than the priority of the calling process
All of this does not make any senses for my application since the msg priority is always 0, the message length uses a #define constant because the message length is always the same size and the MQ_PRIO_RESTRICT flag is not being set.
Has anyone come across this same issue?
thanks,