From: Jouni Malinen Date: Fri, 15 Jan 2016 16:41:30 +0000 (+0200) Subject: EAP peer: Use ifdef PCSC_FUNCS to get rid of compiler warnings X-Git-Tag: hostap_2_6~982 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=269f9d5d100b3963c6b94722da27920e5dca8a8d;p=thirdparty%2Fhostap.git EAP peer: Use ifdef PCSC_FUNCS to get rid of compiler warnings clang started warning about the use of || with constants that came from PCSC_FUNCS not being enabled in the build. It seems to be easier to just ifdef this block out completely since that has the same outcome for builds that do not include PC/SC support. Signed-off-by: Jouni Malinen --- diff --git a/src/eap_peer/eap_sim.c b/src/eap_peer/eap_sim.c index 70292e2de..b97c95db1 100644 --- a/src/eap_peer/eap_sim.c +++ b/src/eap_peer/eap_sim.c @@ -249,6 +249,7 @@ static int eap_sim_gsm_auth(struct eap_sm *sm, struct eap_sim_data *data) return eap_sim_ext_sim_req(sm, data); } +#ifdef PCSC_FUNCS if (conf->pcsc) { if (scard_gsm_auth(sm->scard_ctx, data->rand[0], data->sres[0], data->kc[0]) || @@ -263,6 +264,7 @@ static int eap_sim_gsm_auth(struct eap_sm *sm, struct eap_sim_data *data) } return 0; } +#endif /* PCSC_FUNCS */ #ifdef CONFIG_SIM_SIMULATOR if (conf->password) {