]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
TDLS: Verify that scan results for BSS are available before using them
authorJouni Malinen <jouni.malinen@atheros.com>
Thu, 14 Apr 2011 16:50:26 +0000 (19:50 +0300)
committerJouni Malinen <j@w1.fi>
Thu, 14 Apr 2011 16:50:26 +0000 (19:50 +0300)
wpa_supplicant/wpa_supplicant.c

index 2c5a20c6207b7bc76b189b3ddad3ed8d7130d50e..c4f07d3fdefdb394553402fb63e6e600f152e414 100644 (file)
@@ -1100,7 +1100,9 @@ void wpa_supplicant_associate(struct wpa_supplicant *wpa_s,
        }
 
 #ifdef CONFIG_TDLS
-       wpa_tdls_ap_ies(wpa_s->wpa, (const u8 *) (bss + 1), bss->ie_len);
+       if (bss)
+               wpa_tdls_ap_ies(wpa_s->wpa, (const u8 *) (bss + 1),
+                               bss->ie_len);
 #endif /* CONFIG_TDLS */
 
        if ((wpa_s->drv_flags & WPA_DRIVER_FLAGS_SME) &&