#include <include/qos.h>
Add a message to the library. If the message fails to be added to the internal list because the list is full, the message will be notified with the QOS_EVT_MESSAGE_REMOVED_FROM_LIST event, so that it can be freed if heap allocated. When this API is called, the event QOS_EVT_MESSAGE_NEW is always notified with the corresponding message.
- Parameters
-
message | Pointer to the corresponding message |
- Return values
-
0 | on success. |
-EINVAL | If the message pointer is NULL. |
-ENOMEM | If the internal list is full. |