From: Sunil Ravi Date: Fri, 16 Sep 2022 19:22:02 +0000 (-0700) Subject: Fix compilation error due to use of bitwise '&' with boolean operands X-Git-Tag: hostap_2_11~1682 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c5b950b6af785c46b3ddc5036457a7f012d984a9;p=thirdparty%2Fhostap.git Fix compilation error due to use of bitwise '&' with boolean operands Compiler throws a warning for using bitwise operation in wpa_s_setup_sae_pt() function instead of logical AND operation on two boolean values. Fixes: e81ec0962d02 ("SAE: Use H2E unconditionally with the new AKM suites") Signed-off-by: Sunil Ravi --- diff --git a/wpa_supplicant/wpa_supplicant.c b/wpa_supplicant/wpa_supplicant.c index e085391e2..761017248 100644 --- a/wpa_supplicant/wpa_supplicant.c +++ b/wpa_supplicant/wpa_supplicant.c @@ -2280,7 +2280,7 @@ void wpa_s_setup_sae_pt(struct wpa_config *conf, struct wpa_ssid *ssid) if (!password || (conf->sae_pwe == 0 && !ssid->sae_password_id && - !wpa_key_mgmt_sae_ext_key(ssid->key_mgmt) & + !wpa_key_mgmt_sae_ext_key(ssid->key_mgmt) && !sae_pk_valid_password(password)) || conf->sae_pwe == 3) { /* PT derivation not needed */