Replace MAX_SSID_LEN with SSID_MAX_LEN
This makes source code more consistent. The use within Android driver interface is left as-is to avoid changes in the old PNO interface definition. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
This commit is contained in:
parent
81847c22ba
commit
eaa8eefed1
7 changed files with 9 additions and 10 deletions
|
@ -1814,7 +1814,7 @@ static char * wpa_config_write_mesh_basic_rates(const struct parse_data *data,
|
|||
* functions.
|
||||
*/
|
||||
static const struct parse_data ssid_fields[] = {
|
||||
{ STR_RANGE(ssid, 0, MAX_SSID_LEN) },
|
||||
{ STR_RANGE(ssid, 0, SSID_MAX_LEN) },
|
||||
{ INT_RANGE(scan_ssid, 0, 1) },
|
||||
{ FUNC(bssid) },
|
||||
{ FUNC(bssid_blacklist) },
|
||||
|
@ -2956,7 +2956,7 @@ int wpa_config_set_cred(struct wpa_cred *cred, const char *var,
|
|||
if (os_strcmp(var, "excluded_ssid") == 0) {
|
||||
struct excluded_ssid *e;
|
||||
|
||||
if (len > MAX_SSID_LEN) {
|
||||
if (len > SSID_MAX_LEN) {
|
||||
wpa_printf(MSG_ERROR, "Line %d: invalid "
|
||||
"excluded_ssid length %d", line, (int) len);
|
||||
os_free(val);
|
||||
|
|
|
@ -37,6 +37,7 @@
|
|||
|
||||
#include "config_ssid.h"
|
||||
#include "wps/wps.h"
|
||||
#include "common/ieee802_11_defs.h"
|
||||
#include "common/ieee802_11_common.h"
|
||||
|
||||
|
||||
|
@ -241,7 +242,7 @@ struct wpa_cred {
|
|||
char *phase2;
|
||||
|
||||
struct excluded_ssid {
|
||||
u8 ssid[MAX_SSID_LEN];
|
||||
u8 ssid[SSID_MAX_LEN];
|
||||
size_t ssid_len;
|
||||
} *excluded_ssid;
|
||||
size_t num_excluded_ssid;
|
||||
|
|
|
@ -13,8 +13,6 @@
|
|||
#include "utils/list.h"
|
||||
#include "eap_peer/eap_config.h"
|
||||
|
||||
#define MAX_SSID_LEN 32
|
||||
|
||||
|
||||
#define DEFAULT_EAP_WORKAROUND ((unsigned int) -1)
|
||||
#define DEFAULT_EAPOL_FLAGS (EAPOL_FLAG_REQUIRE_KEY_UNICAST | \
|
||||
|
|
|
@ -1729,7 +1729,7 @@ static int wpa_supplicant_ctrl_iface_status(struct wpa_supplicant *wpa_s,
|
|||
if (ssid) {
|
||||
u8 *_ssid = ssid->ssid;
|
||||
size_t ssid_len = ssid->ssid_len;
|
||||
u8 ssid_buf[MAX_SSID_LEN];
|
||||
u8 ssid_buf[SSID_MAX_LEN];
|
||||
if (ssid_len == 0) {
|
||||
int _res = wpa_drv_get_ssid(wpa_s, ssid_buf);
|
||||
if (_res < 0)
|
||||
|
|
|
@ -1034,10 +1034,10 @@ static int wpas_dbus_get_scan_ssids(DBusMessage *message, DBusMessageIter *var,
|
|||
|
||||
dbus_message_iter_get_fixed_array(&sub_array_iter, &val, &len);
|
||||
|
||||
if (len > MAX_SSID_LEN) {
|
||||
if (len > SSID_MAX_LEN) {
|
||||
wpa_printf(MSG_DEBUG,
|
||||
"%s[dbus]: SSID too long (len=%d max_len=%d)",
|
||||
__func__, len, MAX_SSID_LEN);
|
||||
__func__, len, SSID_MAX_LEN);
|
||||
*reply = wpas_dbus_error_invalid_args(
|
||||
message, "Invalid SSID: too long");
|
||||
return -1;
|
||||
|
|
|
@ -158,7 +158,7 @@ static void wpa_supplicant_update_current_bss(struct wpa_supplicant *wpa_s)
|
|||
static int wpa_supplicant_select_config(struct wpa_supplicant *wpa_s)
|
||||
{
|
||||
struct wpa_ssid *ssid, *old_ssid;
|
||||
u8 drv_ssid[MAX_SSID_LEN];
|
||||
u8 drv_ssid[SSID_MAX_LEN];
|
||||
size_t drv_ssid_len;
|
||||
int res;
|
||||
|
||||
|
|
|
@ -2872,7 +2872,7 @@ int wpa_supplicant_set_debug_params(struct wpa_global *global, int debug_level,
|
|||
struct wpa_ssid * wpa_supplicant_get_ssid(struct wpa_supplicant *wpa_s)
|
||||
{
|
||||
struct wpa_ssid *entry;
|
||||
u8 ssid[MAX_SSID_LEN];
|
||||
u8 ssid[SSID_MAX_LEN];
|
||||
int res;
|
||||
size_t ssid_len;
|
||||
u8 bssid[ETH_ALEN];
|
||||
|
|
Loading…
Reference in a new issue