mirror of
https://github.com/ipmitool/ipmitool.git
synced 2025-05-10 10:37:22 +00:00
lan: Refix 6e2b688e. Fix vlan range checking.
Commit 6e2b688e introduced a bug due to which VLAN id range checking was negated and resulted in error messages printed for correct VLAN ids. Resolves ipmitool/ipmitool#55 Signed-off-by: Alexander Amelkin <alexander@amelkin.msk.ru>
This commit is contained in:
parent
4dc962b614
commit
eed9d5950e
@ -1260,7 +1260,7 @@ ipmi_lan_set_vlan_id(struct ipmi_intf *intf, uint8_t chan, char *string)
|
||||
rc = 0;
|
||||
goto out;
|
||||
}
|
||||
if (IPMI_LANP_IS_VLAN_VALID(id)) {
|
||||
if (!IPMI_LANP_IS_VLAN_VALID(id)) {
|
||||
lprintf(LOG_ERR,
|
||||
"Retrieved VLAN ID %i is out of "
|
||||
"range <%d..%d>.",
|
||||
@ -1285,7 +1285,7 @@ ipmi_lan_set_vlan_id(struct ipmi_intf *intf, uint8_t chan, char *string)
|
||||
goto out;
|
||||
}
|
||||
|
||||
if (IPMI_LANP_IS_VLAN_VALID(id)) {
|
||||
if (!IPMI_LANP_IS_VLAN_VALID(id)) {
|
||||
lprintf(LOG_NOTICE,
|
||||
"VLAN ID must be between %d and %d.",
|
||||
IPMI_LANP_VLAN_ID_MIN,
|
||||
|
Loading…
x
Reference in New Issue
Block a user