Remove unnecessary NULL check from hostapd_config_read_wpa_psk() call
This function is already checking the fname argument against NULL, so use that check on its own instead of duplicating the check in the only caller. Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
9ec3debf24
commit
34e29dfd4b
1 changed files with 1 additions and 7 deletions
|
@ -333,13 +333,7 @@ int hostapd_setup_wpa_psk(struct hostapd_bss_config *conf)
|
|||
ssid->wpa_psk->group = 1;
|
||||
}
|
||||
|
||||
if (ssid->wpa_psk_file) {
|
||||
if (hostapd_config_read_wpa_psk(ssid->wpa_psk_file,
|
||||
&conf->ssid))
|
||||
return -1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
return hostapd_config_read_wpa_psk(ssid->wpa_psk_file, &conf->ssid);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue