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.
This commit is contained in:
Piotr Nakraszewicz 2012-02-11 10:54:40 +02:00 committed by Jouni Malinen
parent ad9ee4d4ca
commit d9a0f66696

View file

@ -2222,7 +2222,8 @@ static int wpas_go_connected(void *ctx, const u8 *dev_addr)
continue; continue;
if (ssid->mode != WPAS_MODE_INFRA) if (ssid->mode != WPAS_MODE_INFRA)
continue; continue;
if (wpa_s->wpa_state != WPA_COMPLETED) if (wpa_s->wpa_state != WPA_COMPLETED &&
wpa_s->wpa_state != WPA_GROUP_HANDSHAKE)
continue; continue;
if (os_memcmp(wpa_s->go_dev_addr, dev_addr, ETH_ALEN) == 0) if (os_memcmp(wpa_s->go_dev_addr, dev_addr, ETH_ALEN) == 0)
return 1; return 1;