OSDN Git Service

Do not try auto connect mechanism in disconnected state, DO NOT MERGE
authorJouni Malinen <jouni@qca.qualcomm.com>
Sun, 12 May 2013 16:15:33 +0000 (19:15 +0300)
committerThe Android Automerger <android-build@google.com>
Tue, 16 Jul 2013 22:26:00 +0000 (15:26 -0700)
This cleans up debug log by not requesting the auto connect on
dissassociation event if we are already in disconnected state and would
not try to connect anyway.

Bug: 8785804
Change-Id: I3ba6cc4c64dd714c0689a39339b6f0da5a06857e
Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
Signed-off-by: Iliyan Malchev <malchev@google.com>
wpa_supplicant/events.c

index 6c0a246..671fd74 100644 (file)
@@ -1957,8 +1957,9 @@ static void wpa_supplicant_event_disassoc_finish(struct wpa_supplicant *wpa_s,
                        "pre-shared key may be incorrect");
                wpas_auth_failed(wpa_s);
        }
-       if (!wpa_s->auto_reconnect_disabled ||
-           wpa_s->key_mgmt == WPA_KEY_MGMT_WPS) {
+       if (!wpa_s->disconnected &&
+           (!wpa_s->auto_reconnect_disabled ||
+            wpa_s->key_mgmt == WPA_KEY_MGMT_WPS)) {
                wpa_dbg(wpa_s, MSG_DEBUG, "Auto connect enabled: try to "
                        "reconnect (wps=%d wpa_state=%d)",
                        wpa_s->key_mgmt == WPA_KEY_MGMT_WPS,