Retry connection when getting NOT_AUTHED

I saw it once with a correct password. Retrying may still fail
but at least it'll try first.
This commit is contained in:
Scott Shawcroft 2020-11-18 16:39:34 -08:00
parent 8ac9b176c9
commit 081aec4429
No known key found for this signature in database
GPG Key ID: 0DFD512649C052DA

View File

@ -59,6 +59,7 @@ static void event_handler(void* arg, esp_event_base_t event_base,
ESP_EARLY_LOGW(TAG, "reason %d 0x%02x", reason, reason);
if (radio->retries_left > 0 &&
(reason == WIFI_REASON_AUTH_EXPIRE ||
reason == WIFI_REASON_NOT_AUTHED ||
reason == WIFI_REASON_ASSOC_EXPIRE ||
reason == WIFI_REASON_CONNECTION_FAIL ||
reason == WIFI_REASON_4WAY_HANDSHAKE_TIMEOUT)) {