Merge pull request #6 from tidyjiang8/master

fix bug about PUBCOMP
This commit is contained in:
Tuan PM
2017-04-30 22:08:58 +07:00
committed by GitHub

2
mqtt.c
View File

@@ -389,7 +389,7 @@ void mqtt_start_receive_schedule(mqtt_client *client)
break; break;
case MQTT_MSG_TYPE_PUBCOMP: case MQTT_MSG_TYPE_PUBCOMP:
if (client->mqtt_state.pending_msg_type == MQTT_MSG_TYPE_PUBLISH && client->mqtt_state.pending_msg_id == msg_id) { if (client->mqtt_state.pending_msg_type == MQTT_MSG_TYPE_PUBREL && client->mqtt_state.pending_msg_id == msg_id) {
mqtt_info("Receive MQTT_MSG_TYPE_PUBCOMP, finish QoS2 publish"); mqtt_info("Receive MQTT_MSG_TYPE_PUBCOMP, finish QoS2 publish");
} }
break; break;