mirror of
https://github.com/espressif/esp-mqtt.git
synced 2025-07-30 10:48:06 +02:00
tabs to spaces corrections
This commit is contained in:
@ -859,20 +859,20 @@ static void esp_mqtt_task(void *pv)
|
|||||||
|
|
||||||
if (platform_tick_get_ms() - client->keepalive_tick > client->connect_info.keepalive * 1000 / 2) {
|
if (platform_tick_get_ms() - client->keepalive_tick > client->connect_info.keepalive * 1000 / 2) {
|
||||||
//No ping resp from last ping => Disconnected
|
//No ping resp from last ping => Disconnected
|
||||||
if(client->wait_for_ping_resp){
|
if(client->wait_for_ping_resp){
|
||||||
ESP_LOGE(TAG, "No PING_RESP, disconnected");
|
ESP_LOGE(TAG, "No PING_RESP, disconnected");
|
||||||
esp_mqtt_abort_connection(client);
|
esp_mqtt_abort_connection(client);
|
||||||
client->wait_for_ping_resp = false;
|
client->wait_for_ping_resp = false;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (esp_mqtt_client_ping(client) == ESP_FAIL) {
|
if (esp_mqtt_client_ping(client) == ESP_FAIL) {
|
||||||
ESP_LOGE(TAG, "Can't send ping, disconnected");
|
ESP_LOGE(TAG, "Can't send ping, disconnected");
|
||||||
esp_mqtt_abort_connection(client);
|
esp_mqtt_abort_connection(client);
|
||||||
break;
|
break;
|
||||||
} else {
|
} else {
|
||||||
client->wait_for_ping_resp = true;
|
client->wait_for_ping_resp = true;
|
||||||
}
|
}
|
||||||
ESP_LOGD(TAG, "PING sent");
|
ESP_LOGD(TAG, "PING sent");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (client->config->refresh_connection_after_ms &&
|
if (client->config->refresh_connection_after_ms &&
|
||||||
|
Reference in New Issue
Block a user