diff --git a/include/mqtt_client.h b/include/mqtt_client.h index e5b2e61..36530b5 100755 --- a/include/mqtt_client.h +++ b/include/mqtt_client.h @@ -48,10 +48,6 @@ typedef struct { typedef esp_mqtt_event_t* esp_mqtt_event_handle_t; - -/** - * \return True on connect success, false on error - */ typedef esp_err_t (* mqtt_event_callback_t)(esp_mqtt_event_handle_t event); diff --git a/mqtt_client.c b/mqtt_client.c index d6c7673..9c1599a 100644 --- a/mqtt_client.c +++ b/mqtt_client.c @@ -708,7 +708,7 @@ static void esp_mqtt_task(void *pv) client->reconnect_tick = platform_tick_get_ms(); ESP_LOGD(TAG, "Reconnecting..."); } - // wait for timeout then change state to INIT + vTaskDelay(client->wait_timeout_ms/2/portTICK_RATE_MS); break; } }