P2P: Do not use reassociation after getting disassociated
authorJouni Malinen <j@w1.fi>
Sun, 10 Jun 2012 16:51:36 +0000 (19:51 +0300)
committerJouni Malinen <j@w1.fi>
Sun, 10 Jun 2012 16:51:36 +0000 (19:51 +0300)
This avoids issues with some APs rejecting a reassociation if the
station is not currently associated as reported by Yossi Wortzel.
The change is based on a patch from Arik Nemtsov.

Signed-hostap: Jouni Malinen <j@w1.fi>

wpa_supplicant/events.c

index d09be6c..e7dfa4e 100644 (file)
@@ -121,6 +121,9 @@ void wpa_supplicant_mark_disassoc(struct wpa_supplicant *wpa_s)
        bssid_changed = !is_zero_ether_addr(wpa_s->bssid);
        os_memset(wpa_s->bssid, 0, ETH_ALEN);
        os_memset(wpa_s->pending_bssid, 0, ETH_ALEN);
+#ifdef CONFIG_SME
+       wpa_s->sme.prev_bssid_set = 0;
+#endif /* CONFIG_SME */
 #ifdef CONFIG_P2P
        os_memset(wpa_s->go_dev_addr, 0, ETH_ALEN);
 #endif /* CONFIG_P2P */