mirror of https://github.com/acidanthera/audk.git
ShellPkg: Update Ifconfig command to accept 32bit subnet mask.
Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Fu Siyuan <siyuan.fu@intel.com> Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Ye Ting <ting.ye@intel.com> Reviewed-by: Wu Jiaxin <jiaxin.wu@intel.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
This commit is contained in:
parent
12ae56cf28
commit
b8bcaafb39
|
@ -1032,6 +1032,7 @@ IfConfigSetInterfaceInfo (
|
|||
SubnetMask = NTOHL (SubnetMask);
|
||||
TempGateway = NTOHL (TempGateway);
|
||||
if ((SubnetMask != 0) &&
|
||||
(SubnetMask != 0xFFFFFFFFu) &&
|
||||
!NetIp4IsUnicast (TempGateway, SubnetMask)) {
|
||||
ShellPrintHiiEx (-1, -1, NULL, STRING_TOKEN (STR_IFCONFIG_INVALID_GATEWAY), gShellNetwork1HiiHandle, VarArg->Arg);
|
||||
ShellStatus = SHELL_INVALID_PARAMETER;
|
||||
|
|
Loading…
Reference in New Issue