Fix megre code some error
This commit is contained in:
parent
a75ac5487d
commit
dba4c56946
|
@ -993,7 +993,6 @@ void mqtt_client_thread(void* pvParameters)
|
|||
mqtt_client_set_last_msec(ne_os_ticks_ms(xTaskGetTickCount()));
|
||||
do {
|
||||
/* Generate topic message */
|
||||
cnt++;
|
||||
|
||||
rc = mqtt_client_handle_message(pclient);
|
||||
if (rc < 0) {
|
||||
|
@ -1005,22 +1004,17 @@ void mqtt_client_thread(void* pvParameters)
|
|||
MSG_ctrl_cmd_process(pclient);
|
||||
|
||||
/* handle the MQTT packet received from TCP or SSL connection */
|
||||
|
||||
if(cnt++ % 100 == 0)
|
||||
{
|
||||
MQTT_LOG_EX(LOG_Info, "MQTT Yield: FreeSize=%x, MinFreeSize=%x, CNT=%d\r\n",
|
||||
(int)system_get_free_heap_size(), (int)xPortGetMinimumEverFreeHeapSize(), cnt);
|
||||
}
|
||||
rc = IOT_MQTT_Yield(pclient, 200);
|
||||
|
||||
MQTT_LOG_EX(LOG_Info, "MQTT Yield: FreeSize=%x, MinFreeSize=%x, CNT=%x\r\n", (int)system_get_free_heap_size(), (int)xPortGetMinimumEverFreeHeapSize(), cnt);
|
||||
rc = IOT_MQTT_Yield(pclient, 200);
|
||||
|
||||
if (rc < 0) {
|
||||
MQTT_LOG_EX(LOG_Error, "Yield failed\r\n");
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
#if 0 //test code for simulate MQTT publish
|
||||
if ((cnt&0xf) == 0) {
|
||||
mqtt_client_test_publish(pclient, cnt);
|
||||
|
|
Loading…
Reference in New Issue