From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Permerror (SPF Permanent Error: Two or more type TXT spf records found.) identity=mailfrom; client-ip=134.134.136.31; helo=mga06.intel.com; envelope-from=ting.ye@intel.com; receiver=edk2-devel@lists.01.org Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id A52EF210F75B7 for ; Fri, 31 Aug 2018 00:46:55 -0700 (PDT) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 31 Aug 2018 00:46:46 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.53,309,1531810800"; d="scan'208";a="86489777" Received: from fmsmsx108.amr.corp.intel.com ([10.18.124.206]) by orsmga001.jf.intel.com with ESMTP; 31 Aug 2018 00:46:41 -0700 Received: from fmsmsx123.amr.corp.intel.com (10.18.125.38) by FMSMSX108.amr.corp.intel.com (10.18.124.206) with Microsoft SMTP Server (TLS) id 14.3.319.2; Fri, 31 Aug 2018 00:46:41 -0700 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by fmsmsx123.amr.corp.intel.com (10.18.125.38) with Microsoft SMTP Server (TLS) id 14.3.319.2; Fri, 31 Aug 2018 00:46:41 -0700 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.240]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.205]) with mapi id 14.03.0319.002; Fri, 31 Aug 2018 15:46:39 +0800 From: "Ye, Ting" To: "Fu, Siyuan" , "edk2-devel@lists.01.org" CC: "Ni, Ruiyu" , "Wu, Jiaxin" Thread-Topic: [Patch 2/2] ShellPkg: Update Ifconfig command to accept 32bit subnet mask. Thread-Index: AQHUPnHiceR4aIGtN0y8Awh/U5KDhaTZgI6g Date: Fri, 31 Aug 2018 07:46:39 +0000 Message-ID: References: <20180828015235.60368-1-siyuan.fu@intel.com> <20180828015235.60368-3-siyuan.fu@intel.com> In-Reply-To: <20180828015235.60368-3-siyuan.fu@intel.com> Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [Patch 2/2] ShellPkg: Update Ifconfig command to accept 32bit subnet mask. X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 31 Aug 2018 07:46:55 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reveiewed-by: Ye Ting =20 -----Original Message----- From: Fu, Siyuan=20 Sent: Tuesday, August 28, 2018 9:53 AM To: edk2-devel@lists.01.org Cc: Ni, Ruiyu ; Ye, Ting ; Wu, Jiaxi= n Subject: [Patch 2/2] ShellPkg: Update Ifconfig command to accept 32bit subn= et mask. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Fu Siyuan Cc: Ruiyu Ni Cc: Ye Ting Cc: Wu Jiaxin --- ShellPkg/Library/UefiShellNetwork1CommandsLib/Ifconfig.c | 1 + 1 file changed, 1 insertion(+) diff --git a/ShellPkg/Library/UefiShellNetwork1CommandsLib/Ifconfig.c b/She= llPkg/Library/UefiShellNetwork1CommandsLib/Ifconfig.c index 52415e0ad0..e9f644c739 100644 --- a/ShellPkg/Library/UefiShellNetwork1CommandsLib/Ifconfig.c +++ b/ShellPkg/Library/UefiShellNetwork1CommandsLib/Ifconfig.c @@ -1032,6 +1032,7 @@ IfConfigSetInterfaceInfo ( SubnetMask =3D NTOHL (SubnetMask); TempGateway =3D NTOHL (TempGateway); if ((SubnetMask !=3D 0) && + (SubnetMask !=3D 0xFFFFFFFFu) &&=20 !NetIp4IsUnicast (TempGateway, SubnetMask)) { ShellPrintHiiEx (-1, -1, NULL, STRING_TOKEN (STR_IFCONFIG_INVALID_= GATEWAY), gShellNetwork1HiiHandle, VarArg->Arg); ShellStatus =3D SHELL_INVALID_PARAMETER; --=20 2.18.0.windows.1