Fix for MQTT PUBACK loop

Conflicts:
	app/modules/mqtt.c
This commit is contained in:
Jonathan karras 2015-10-12 23:49:10 -06:00
parent f11a5df955
commit 57c2e6eacd
1 changed files with 21 additions and 21 deletions

View File

@ -446,7 +446,7 @@ static void mqtt_socket_sent(void *arg)
lua_rawgeti(mud->L, LUA_REGISTRYINDEX, mud->cb_puback_ref);
lua_rawgeti(mud->L, LUA_REGISTRYINDEX, mud->self_ref); // pass the userdata to callback func in lua
lua_call(mud->L, 1, 0);
} else if(node && node->msg_type == MQTT_MSG_TYPE_PUBACK && node->publish_qos == 1) {
} else if(node && node->msg_type == MQTT_MSG_TYPE_PUBACK) {
msg_destroy(msg_dequeue(&(mud->mqtt_state.pending_msg_q)));
} else if(node && node->msg_type == MQTT_MSG_TYPE_PUBCOMP) {
msg_destroy(msg_dequeue(&(mud->mqtt_state.pending_msg_q)));