aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant/wps_supplicant.c
diff options
context:
space:
mode:
authorJouni Malinen <jouni@qca.qualcomm.com>2015-04-07 09:00:13 (GMT)
committerJouni Malinen <j@w1.fi>2015-04-22 08:44:18 (GMT)
commitd9d1b9527a77a0a3ecd6841dffc8316007f1411d (patch)
treeb2df339768c08ee428d315f1fdf9621f8d552f78 /wpa_supplicant/wps_supplicant.c
parent65b10253d62eba5badc2d5d1a2433e3b3d00f215 (diff)
downloadhostap-d9d1b9527a77a0a3ecd6841dffc8316007f1411d.zip
hostap-d9d1b9527a77a0a3ecd6841dffc8316007f1411d.tar.gz
hostap-d9d1b9527a77a0a3ecd6841dffc8316007f1411d.tar.bz2
Use SSID_MAX_LEN define instead of value 32 when comparing SSID length
This makes the implementation easier to understand. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
Diffstat (limited to 'wpa_supplicant/wps_supplicant.c')
-rw-r--r--wpa_supplicant/wps_supplicant.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/wpa_supplicant/wps_supplicant.c b/wpa_supplicant/wps_supplicant.c
index eabe986..52594a1 100644
--- a/wpa_supplicant/wps_supplicant.c
+++ b/wpa_supplicant/wps_supplicant.c
@@ -1910,7 +1910,7 @@ static int wpas_wps_network_to_cred(struct wpa_ssid *ssid,
struct wps_credential *cred)
{
os_memset(cred, 0, sizeof(*cred));
- if (ssid->ssid_len > 32)
+ if (ssid->ssid_len > SSID_MAX_LEN)
return -1;
os_memcpy(cred->ssid, ssid->ssid, ssid->ssid_len);
cred->ssid_len = ssid->ssid_len;