mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-27 04:36:31 +00:00
Fix core 2.0.12 exception
This commit is contained in:
parent
4c6ff44e42
commit
f9fd813842
@ -911,9 +911,11 @@ void MqttDisconnected(int state) {
|
|||||||
Mqtt.retry_counter_delay++;
|
Mqtt.retry_counter_delay++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (MqttClient.connected()) {
|
||||||
MqttClient.disconnect();
|
MqttClient.disconnect();
|
||||||
// Check if this solves intermittent MQTT re-connection failures when broker is restarted
|
// Check if this solves intermittent MQTT re-connection failures when broker is restarted
|
||||||
EspClient.stop();
|
EspClient.stop();
|
||||||
|
}
|
||||||
|
|
||||||
AddLog(LOG_LEVEL_INFO, PSTR(D_LOG_MQTT D_CONNECT_FAILED_TO " %s:%d, rc %d. " D_RETRY_IN " %d " D_UNIT_SECOND),
|
AddLog(LOG_LEVEL_INFO, PSTR(D_LOG_MQTT D_CONNECT_FAILED_TO " %s:%d, rc %d. " D_RETRY_IN " %d " D_UNIT_SECOND),
|
||||||
SettingsText(SET_MQTT_HOST), Settings->mqtt_port, state, Mqtt.retry_counter);
|
SettingsText(SET_MQTT_HOST), Settings->mqtt_port, state, Mqtt.retry_counter);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user