aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPiotr Nakraszewicz <Piotr.Nakraszewicz@tieto.com>2012-02-11 08:54:40 (GMT)
committerJouni Malinen <j@w1.fi>2012-02-11 08:54:40 (GMT)
commitd9a0f666960ee096fbaf21e72818772dbfa043b7 (patch)
treea825d655d8fee80e9c06dd6b98f49388e94027cb
parentad9ee4d4cadd362361aee31f6a8cd49f300ccf19 (diff)
downloadhostap-d9a0f666960ee096fbaf21e72818772dbfa043b7.zip
hostap-d9a0f666960ee096fbaf21e72818772dbfa043b7.tar.gz
hostap-d9a0f666960ee096fbaf21e72818772dbfa043b7.tar.bz2
P2P: Do not expire GO peer entry during group rekeying
If wpas_go_connected() is called during group rekeying the P2P GO peer will expire. To prevent that check if group rekeying is not in progress.
-rw-r--r--wpa_supplicant/p2p_supplicant.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/wpa_supplicant/p2p_supplicant.c b/wpa_supplicant/p2p_supplicant.c
index ec4ba4a..bde3ba8 100644
--- a/wpa_supplicant/p2p_supplicant.c
+++ b/wpa_supplicant/p2p_supplicant.c
@@ -2222,7 +2222,8 @@ static int wpas_go_connected(void *ctx, const u8 *dev_addr)
continue;
if (ssid->mode != WPAS_MODE_INFRA)
continue;
- if (wpa_s->wpa_state != WPA_COMPLETED)
+ if (wpa_s->wpa_state != WPA_COMPLETED &&
+ wpa_s->wpa_state != WPA_GROUP_HANDSHAKE)
continue;
if (os_memcmp(wpa_s->go_dev_addr, dev_addr, ETH_ALEN) == 0)
return 1;