From nobody Sat Nov 2 16:37:21 2024 Delivered-To: importer@patchew.org Received-SPF: none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) client-ip=198.145.21.10; envelope-from=edk2-devel-bounces@lists.01.org; helo=ml01.01.org; Authentication-Results: mx.zoho.com; spf=none (zoho.com: 198.145.21.10 is neither permitted nor denied by domain of lists.01.org) smtp.mailfrom=edk2-devel-bounces@lists.01.org; Return-Path: Received: from ml01.01.org (ml01.01.org [198.145.21.10]) by mx.zohomail.com with SMTPS id 1487827864161864.797982505733; Wed, 22 Feb 2017 21:31:04 -0800 (PST) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 03A068224F; Wed, 22 Feb 2017 21:31:03 -0800 (PST) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) (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 BAE768224F for ; Wed, 22 Feb 2017 21:31:01 -0800 (PST) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga105.jf.intel.com with ESMTP; 22 Feb 2017 21:31:01 -0800 Received: from jiaxinwu-mobl2.ccr.corp.intel.com ([10.239.196.105]) by orsmga003.jf.intel.com with ESMTP; 22 Feb 2017 21:31:00 -0800 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.35,197,1484035200"; d="scan'208";a="937113016" From: Jiaxin Wu To: edk2-devel@lists.01.org Date: Thu, 23 Feb 2017 13:30:56 +0800 Message-Id: <1487827857-38844-2-git-send-email-jiaxin.wu@intel.com> X-Mailer: git-send-email 1.9.5.msysgit.1 In-Reply-To: <1487827857-38844-1-git-send-email-jiaxin.wu@intel.com> References: <1487827857-38844-1-git-send-email-jiaxin.wu@intel.com> Subject: [edk2] [Patch 1/2] MdeModulePkg/Ip4Dxe: Ignore duplicated DNS address check X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ye Ting , Fu Siyuan , Wu Jiaxin MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Having duplicated DNS server IPs specified is not an ideal configuration, but not an error condition. This patch is to remove the duplicated DNS address check to allow the same DNS address setting in SetData(). Cc: Hegde Nagaraj P Cc: Subramanian Sriram Cc: Ye Ting Cc: Fu Siyuan Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Wu Jiaxin --- MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c b/MdeMo= dulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c index a6a3da8..0b56d76 100644 --- a/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c +++ b/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c @@ -703,11 +703,10 @@ Ip4Config2SetDnsServerWorker ( IN VOID *Data ) { UINTN OldIndex; UINTN NewIndex; - UINTN Index1; EFI_IPv4_ADDRESS *OldDns; EFI_IPv4_ADDRESS *NewDns; UINTN OldDnsCount; UINTN NewDnsCount; IP4_CONFIG2_DATA_ITEM *Item; @@ -745,19 +744,10 @@ Ip4Config2SetDnsServerWorker ( FreePool (Tmp); } return EFI_INVALID_PARAMETER; } =20 - for (Index1 =3D NewIndex + 1; Index1 < NewDnsCount; Index1++) { - if (EFI_IP4_EQUAL (NewDns + NewIndex, NewDns + Index1)) { - if (Tmp !=3D NULL) { - FreePool (Tmp); - } - return EFI_INVALID_PARAMETER; - } - } - if (OneAdded) { // // If any address in the new setting is not in the old settings, ski= p the // comparision below. // --=20 1.9.5.msysgit.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel