mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-09-06 17:14:02 +00:00
libnm-util: fix WEP key type comparison in nm_utils_wep_key_valid()
This commit is contained in:
parent
22d2f571ce
commit
bfc20af513
|
@ -827,7 +827,8 @@ nm_utils_wep_key_valid (const char *key, NMWepKeyType wep_type)
|
|||
return FALSE;
|
||||
|
||||
keylen = strlen (key);
|
||||
if (wep_type == NM_WEP_KEY_TYPE_KEY || NM_WEP_KEY_TYPE_UNKNOWN) {
|
||||
if ( wep_type == NM_WEP_KEY_TYPE_KEY
|
||||
|| wep_type == NM_WEP_KEY_TYPE_UNKNOWN) {
|
||||
if (keylen == 10 || keylen == 26) {
|
||||
/* Hex key */
|
||||
for (i = 0; i < keylen; i++) {
|
||||
|
|
Loading…
Reference in a new issue