docs: Updated publish message return code to make it clear that message_id is always 0 for QoS 0

Closes https://github.com/espressif/esp-mqtt/issues/127
This commit is contained in:
David Cermak
2019-09-27 16:23:24 +02:00
parent 04253b2b07
commit 9fbd7d9244

View File

@ -225,8 +225,8 @@ int esp_mqtt_client_unsubscribe(esp_mqtt_client_handle_t client, const char *top
* @param qos qos of publish message
* @param retain ratain flag
*
* @return message_id of the subscribe message on success
* 0 if cannot publish
* @return message_id of the publish message (for QoS 0 message_id will always be zero) on success.
* -1 on failure.
*/
int esp_mqtt_client_publish(esp_mqtt_client_handle_t client, const char *topic, const char *data, int len, int qos, int retain);