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>
This commit is contained in:
Jouni Malinen 2015-04-07 12:00:13 +03:00 committed by Jouni Malinen
parent 65b10253d6
commit d9d1b9527a
24 changed files with 65 additions and 54 deletions

View file

@ -8,6 +8,7 @@
#include "includes.h"
#include "common/ieee802_11_defs.h"
#include "common.h"
@ -609,7 +610,7 @@ size_t printf_decode(u8 *buf, size_t maxlen, const char *str)
*/
const char * wpa_ssid_txt(const u8 *ssid, size_t ssid_len)
{
static char ssid_txt[32 * 4 + 1];
static char ssid_txt[SSID_MAX_LEN * 4 + 1];
if (ssid == NULL) {
ssid_txt[0] = '\0';