Use more consistent iface->conf checks

Commit f1df4fbfc7 ("mesh: Use setup completion callback to complete
mesh join") added a check for iface->conf being NULL into a debug print.
However, it is not clear how that could be NULL here. In any case,
setup_interface() could end up dereferencing iface->conf in the call to
hostapd_validate_bssid_configuration(), so better be consistent with the
checks and not get warnings from static analyzers regardless of whether
this can happen in practice.

Signed-off-by: Jouni Malinen <j@w1.fi>
master
Jouni Malinen 3 years ago
parent b8211e1e75
commit 57fec19dab

@ -2308,10 +2308,12 @@ int hostapd_setup_interface(struct hostapd_iface *iface)
{
int ret;
if (!iface->conf)
return -1;
ret = setup_interface(iface);
if (ret) {
wpa_printf(MSG_ERROR, "%s: Unable to setup interface.",
iface->conf ? iface->conf->bss[0]->iface : "N/A");
iface->conf->bss[0]->iface);
return -1;
}

Loading…
Cancel
Save