Fix wpa_auth_iface_iter() to skip BSSes without Authenticator
This could cause NULL pointer deference if multi-BSS configuration was used with OKC in some cases.
This commit is contained in:
parent
b766a9a293
commit
03bcb0af0d
1 changed files with 2 additions and 1 deletions
|
@ -270,7 +270,8 @@ static int wpa_auth_iface_iter(struct hostapd_iface *iface, void *ctx)
|
||||||
struct wpa_auth_iface_iter_data *data = ctx;
|
struct wpa_auth_iface_iter_data *data = ctx;
|
||||||
size_t i;
|
size_t i;
|
||||||
for (i = 0; i < iface->num_bss; i++) {
|
for (i = 0; i < iface->num_bss; i++) {
|
||||||
if (data->cb(iface->bss[i]->wpa_auth, data->cb_ctx))
|
if (iface->bss[i]->wpa_auth &&
|
||||||
|
data->cb(iface->bss[i]->wpa_auth, data->cb_ctx))
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Add table
Reference in a new issue