[PSDK] Define maximum SSID length properly (#7394)

Avoid using magic numbers for structures and ease the day for those
who do not remember IEEE 802.11 specifications by heart.

- Add a #define that matches by name with one used since day one
  of Visual Studio 2008 (VS2005 does not have Native Wi-Fi SDK)
- Remove magic constant from DOT11_SSID.ucSSID size definition

Reference: https://learn.microsoft.com/en-us/windows/win32/nativewifi/dot11-ssid
CORE-6905
This commit is contained in:
Vitaly Orekhov 2024-09-28 18:28:15 +03:00 committed by GitHub
parent 1c0b769e96
commit c2082ce92a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 1 deletions

View file

@ -64,7 +64,7 @@ typedef DOT11_MAC_ADDRESS* PDOT11_MAC_ADDRESS;
typedef struct _DOT11_SSID {
ULONG uSSIDLength;
UCHAR ucSSID[32];
UCHAR ucSSID[DOT11_SSID_MAX_LENGTH];
} DOT11_SSID, *PDOT11_SSID;
typedef struct _DOT11_BSSID_LIST {

View file

@ -7,6 +7,7 @@ typedef enum _DOT11_BSS_TYPE {
dot11_BSS_type_any
} DOT11_BSS_TYPE;
#define DOT11_SSID_MAX_LENGTH 32
#endif