diff options
author | Eyal Shapira <eyal@wizery.com> | 2012-07-22 02:49:48 +0300 |
---|---|---|
committer | Arik Nemtsov <arik@wizery.com> | 2012-08-02 13:04:02 +0300 |
commit | 229bb110ab53bebd947b505e519d33d72f15442b (patch) | |
tree | cfd5616e88d9d8b8d987c521fcd4544429729987 /src | |
parent | 9e56cb4dbf692d0f42c285cd666d8a07acdfe014 (diff) | |
download | external_wpa_supplicant_8_ti-229bb110ab53bebd947b505e519d33d72f15442b.zip external_wpa_supplicant_8_ti-229bb110ab53bebd947b505e519d33d72f15442b.tar.gz external_wpa_supplicant_8_ti-229bb110ab53bebd947b505e519d33d72f15442b.tar.bz2 |
Fix a crash in WPS PBC overlap (BRCM)
Supposedly fixed a crash which occurs during actual PBC overlap
according to BRCM commit log.
(Not quite sure what's the exact cause of the crash here. However
this looks like a non BRCM specific change so take it).
p2p_dev_addr can be NULL in some of the calls. Might cause a problem ?)
Signed-off-by: Eyal Shapira <eyal@wizery.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/wps/wps_registrar.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/wps/wps_registrar.c b/src/wps/wps_registrar.c index 154c2b4..44bb006 100644 --- a/src/wps/wps_registrar.c +++ b/src/wps/wps_registrar.c @@ -361,8 +361,13 @@ static void wps_registrar_remove_pbc_session(struct wps_registrar *reg, pbc = reg->pbc_sessions; while (pbc) { if (os_memcmp(pbc->uuid_e, uuid_e, WPS_UUID_LEN) == 0 || +#ifdef ANDROID_P2P + (p2p_dev_addr && !is_zero_ether_addr(pbc->addr) && + os_memcmp(pbc->addr, p2p_dev_addr, ETH_ALEN) == +#else (p2p_dev_addr && !is_zero_ether_addr(reg->p2p_dev_addr) && os_memcmp(reg->p2p_dev_addr, p2p_dev_addr, ETH_ALEN) == +#endif 0)) { if (prev) prev->next = pbc->next; |