From 7d801615b26adc7f5dccfa9a36faef1f8f62ee96 Mon Sep 17 00:00:00 2001 From: tangyuxin <462747508@qq.com> Date: Wed, 31 Jul 2019 11:57:37 +0800 Subject: [PATCH] =?UTF-8?q?[components][drivers][wlan]=20=E4=BF=AE?= =?UTF-8?q?=E5=A4=8D=E5=AF=86=E7=A0=81=E4=B8=B4=E7=95=8C=E5=80=BC=E5=88=A4?= =?UTF-8?q?=E6=96=AD=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/drivers/wlan/wlan_dev.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/components/drivers/wlan/wlan_dev.c b/components/drivers/wlan/wlan_dev.c index 2490c2c456..375b27fb10 100644 --- a/components/drivers/wlan/wlan_dev.c +++ b/components/drivers/wlan/wlan_dev.c @@ -147,8 +147,8 @@ rt_err_t rt_wlan_dev_ap_start(struct rt_wlan_device *device, struct rt_wlan_info return -RT_ERROR; } - if ((password_len >= RT_WLAN_PASSWORD_MAX_LENGTH) || - (info->ssid.len >= RT_WLAN_SSID_MAX_LENGTH)) + if ((password_len > RT_WLAN_PASSWORD_MAX_LENGTH) || + (info->ssid.len > RT_WLAN_SSID_MAX_LENGTH)) { LOG_E("L:%d password or ssid is to long", __LINE__); return -RT_ERROR; @@ -528,7 +528,7 @@ rt_err_t rt_wlan_dev_scan(struct rt_wlan_device *device, struct rt_wlan_info *in if (info != RT_NULL) { - if (info->ssid.len >= RT_WLAN_SSID_MAX_LENGTH) + if (info->ssid.len > RT_WLAN_SSID_MAX_LENGTH) { LOG_E("L:%d ssid is to long", __LINE__); return -RT_EINVAL;