MQTT: fix MQTT_PUBLISHED_EVENT not always being posted

- Some PUBLISHED events would not be posted due to outbox messages being deleted before receiving PUBCOMP.
 - Current pending_message is no longer used to check for acknowledgements, as it doesn't work with multiple or out of order messages.

Closes https://github.com/espressif/esp-mqtt/issues/132
This commit is contained in:
Marius Vikhammer
2019-10-03 13:28:51 +02:00
committed by David Cermak
parent 78e2a7050e
commit 3e35fc8323
2 changed files with 3 additions and 5 deletions
+1
View File
@@ -30,6 +30,7 @@ typedef struct outbox_message {
typedef enum pending_state {
QUEUED,
TRANSMITTED,
ACKNOWLEDGED,
CONFIRMED
} pending_state_t;