From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail05.groups.io (mail05.groups.io [45.79.224.7]) by spool.mail.gandi.net (Postfix) with ESMTPS id 72E5774003D for ; Fri, 12 Jul 2024 05:14:58 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=fFI03iiehyZyJCmmqzivH7osXFPqnJ9o6jpgH5EPz4c=; c=relaxed/simple; d=groups.io; h=From:To:CC:Subject:Thread-Topic:Thread-Index:Date:Message-ID:References:In-Reply-To:Accept-Language:MIME-Version:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Resent-Date:Resent-From:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Language:Content-Type:Content-Transfer-Encoding; s=20240206; t=1720761298; v=1; b=Kq2bwF1tcyb4V2+YQhI0aCe1MYX7A/9s1O1z8hR9MyeaGEtDzNTgcS94g/+Fw3hwmj3CJVWq hs1W4/J/cYnJZwk6Sb/Jd0cHOWYtIoWY0H3U6WjXxTXE3XOyY/b9K0OqkSUoKF8WIzxsfZBmAwK B7akAmagxd5mD0TnZvQCofInd035zpLVc3gLPZrSXzrRUuUaB2yTbctlTrpcmBjh61xMuKWnS9K jDSh5068/0egEYkP5LyjKJBE17nV7I58slC4F+wp2Vp/ZV08OAblhaJVSxFifCa59xjNRlHVO92 QOaDwmo8iCEu3UeMucrDazYJsW/Y0mq16mi+PKi9K4j/A== X-Received: by 127.0.0.2 with SMTP id XrhkYY7687511xzY8h0ZhUOv; Thu, 11 Jul 2024 22:14:57 -0700 X-Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.7]) by mx.groups.io with SMTP id smtpd.web10.1053.1720761296710111363 for ; Thu, 11 Jul 2024 22:14:56 -0700 X-CSE-ConnectionGUID: Gd3UXEjGSiuHEvykTnrU+g== X-CSE-MsgGUID: aORa5MAMQzetc7nrxbE57w== X-IronPort-AV: E=McAfee;i="6700,10204,11130"; a="43603213" X-IronPort-AV: E=Sophos;i="6.09,202,1716274800"; d="scan'208";a="43603213" X-Received: from orviesa004.jf.intel.com ([10.64.159.144]) by fmvoesa101.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 11 Jul 2024 22:14:56 -0700 X-CSE-ConnectionGUID: uUuxvaaRRICvqkTE4E5XuA== X-CSE-MsgGUID: 91sc7UzAQ7yC1SifqLGgtw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.09,202,1716274800"; d="scan'208";a="53988504" X-Received: from fmsmsx601.amr.corp.intel.com ([10.18.126.81]) by orviesa004.jf.intel.com with ESMTP/TLS/AES256-GCM-SHA384; 11 Jul 2024 22:14:56 -0700 X-Received: from fmsmsx610.amr.corp.intel.com (10.18.126.90) by fmsmsx601.amr.corp.intel.com (10.18.126.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Thu, 11 Jul 2024 22:14:55 -0700 X-Received: from fmsedg602.ED.cps.intel.com (10.1.192.136) by fmsmsx610.amr.corp.intel.com (10.18.126.90) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39 via Frontend Transport; Thu, 11 Jul 2024 22:14:54 -0700 X-Received: from NAM10-DM6-obe.outbound.protection.outlook.com (104.47.58.101) by edgegateway.intel.com (192.55.55.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Thu, 11 Jul 2024 22:14:53 -0700 X-Received: from MW5PR11MB5906.namprd11.prod.outlook.com (2603:10b6:303:1a0::21) by MN2PR11MB4568.namprd11.prod.outlook.com (2603:10b6:208:266::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7741.36; Fri, 12 Jul 2024 05:14:46 +0000 X-Received: from MW5PR11MB5906.namprd11.prod.outlook.com ([fe80::4f00:440:c5eb:87e2]) by MW5PR11MB5906.namprd11.prod.outlook.com ([fe80::4f00:440:c5eb:87e2%7]) with mapi id 15.20.7762.020; Fri, 12 Jul 2024 05:14:45 +0000 From: "Yuwei Chen" To: "Kuo, Ted" , "devel@edk2.groups.io" CC: Liming Gao , "Feng, Bob C" Subject: Re: [edk2-devel][PATCH][edk2-staging] BaseTools: Fix BaseTools compilation issues Thread-Topic: [edk2-devel][PATCH][edk2-staging] BaseTools: Fix BaseTools compilation issues Thread-Index: AQHazr6J3hEw85QkNU+yqcjNoauWY7Hyl01g Date: Fri, 12 Jul 2024 05:14:45 +0000 Message-ID: References: <1287dcdf308fe882db0ed2d229f8ea28434b3707.1720171761.git.ted.kuo@intel.com> In-Reply-To: <1287dcdf308fe882db0ed2d229f8ea28434b3707.1720171761.git.ted.kuo@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-publictraffictype: Email x-ms-traffictypediagnostic: MW5PR11MB5906:EE_|MN2PR11MB4568:EE_ x-ms-office365-filtering-correlation-id: b5650034-dfe9-4559-0e6d-08dca2318b86 x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam-message-info: =?us-ascii?Q?1IESJhEBTAH/eHGr0zOHJRXbZPuANm7oWCv5kj8bsRAw5ubhHTmaXETvw4Xx?= =?us-ascii?Q?/1PRPP8JBWOBEcQFJ6AswfypQTwjzvnhPBKHNQ3q3F8/frG1iVsLo/ebkH3U?= =?us-ascii?Q?deHxCj/2n7jxvEsTfdQoHWKYE80pNxjXLsKzdGlcgMMpIEOwMDXzhzKrUxyk?= =?us-ascii?Q?USTJU8NMU+/8Rx3JrAuM47+j63McICHonyQzfetE1o4egu7iE+6hp4xuKX5/?= =?us-ascii?Q?0Zpw5PUZp3lPuTUkOlnGQGshI32dxVSbG04obTug71lKs3glr5KAmTfarQn2?= =?us-ascii?Q?sCxg7JFI9Jy9ESr6Megmw2Y3PQ0CBAesNgj7heDaT7mRbXDD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d5iFvZaviOgHOvlkyxBLuvqwOWL?= =?us-ascii?Q?2Mq2htaHgQGrkUqjxfJZqbcDGdZNpkzDIoXHsXARiHlHa08BbKJKHoPX7tsj?= =?us-ascii?Q?S+IVu6Pl4CNRxjTgQx5kN8V/IptzNnLYkbikRU10oghNOSQC2gs3Log7LUHE?= =?us-ascii?Q?1ccPI7o=3D?= x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?us-ascii?Q?TWBwcc7eR/U76pCjjR45RDxWrPFJEi9i5stxEfLF6ZagPxFlY9AbIh/xn/CD?= =?us-ascii?Q?wQTj+/joBZJb46/BJxBUJ8DtMjtXGN6I2GZzKTqt6LQP3m04IcpPKHBijVtk?= =?us-ascii?Q?Gq1gN0pd8LRIWRkNLVQVg25wDoE7ss548OTXPH4Z4/B/0fl/VOgaRj3LjqXl?= =?us-ascii?Q?VV9cDqbFgLLD7D6wcfqiDDJfTdoQZFTUN0zCAItokZfF+K6I//QA3xHIt18P?= =?us-ascii?Q?vL3GgaheUXPw1s9/6qz3kWa8cA4mxXIaveUNcga6RvI+Q3c6JheS69Ks7YwO?= =?us-ascii?Q?JwYmuGv+036Z2czbsB+4Tp3mr3Yz1kQDqklU7NclNNuxZ23zgxKMfX7f9RpI?= =?us-ascii?Q?bOvY+EKONxjFuFSDsq0qQh47Sk63q9nPhZfVGNqjTjxxhhnQEmrvqw99UMwh?= =?us-ascii?Q?gltxh10HUEe/uPPw/aiXmcnzygUXhxBiiD00iunySeCr966r04zbfcH7MCsu?= =?us-ascii?Q?gBl1r147GANqFBWQRduV6pMQJREWT3CZiGuYSZnVKc26+DY256OjflCRpqMG?= =?us-ascii?Q?zFSL5KAru3cDdQmNhEon0piSNnVyUskVyLMIlNSWZOofH7s+aOesf49sT5i0?= =?us-ascii?Q?Z04iIiAvcUB1Ha6d/CVm9DYDUMIiCDS4i0nY7PXMOW/UgSutYAObBTZVNqZY?= =?us-ascii?Q?73k7J7tMYSPYxDRoLY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ii?Q?jLY/phzGzNtExB/DaQwHvsNfJrg5TZ+RDcxnaZyK?= MIME-Version: 1.0 X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MW5PR11MB5906.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: b5650034-dfe9-4559-0e6d-08dca2318b86 X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Jul 2024 05:14:45.7110 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: iCY0AD7tH5GBAir12A3FxLPZBc8rIx7BOPLMBYxqBlY8b1/fjPw4H0HHtPLXwISRlSjKXt+ZcCcElaVYxEfzhw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR11MB4568 X-OriginatorOrg: intel.com Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Resent-Date: Thu, 11 Jul 2024 22:14:57 -0700 Resent-From: yuwei.chen@intel.com Reply-To: devel@edk2.groups.io,yuwei.chen@intel.com List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: X-Gm-Message-State: sj7CJ12ksTiDeaCyVi8v3ZJlx7686176AA= Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20240206 header.b=Kq2bwF1t; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=intel.com (policy=none); spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 45.79.224.7 as permitted sender) smtp.mailfrom=bounce@groups.io Reviewed-by: Yuwei Chen > -----Original Message----- > From: Kuo, Ted > Sent: Friday, July 5, 2024 5:32 PM > To: devel@edk2.groups.io > Cc: Liming Gao ; Feng, Bob C > ; Chen, Christine > Subject: [edk2-devel][PATCH][edk2-staging] BaseTools: Fix BaseTools > compilation issues >=20 > https://bugzilla.tianocore.org/show_bug.cgi?id=3D4798 > This patch removes unused variables that were causing compilation errors > when building EDK2/BaseTools with GCC with the compiler flag Wunused- > but-set-variable set. >=20 > Cc: Liming Gao > Cc: Bob Feng > Cc: Yuwei Chen > Signed-off-by: Ted Kuo > --- > BaseTools/Source/C/BfmLib/BfmLib.c | 26 -------------------------- > BaseTools/Source/C/FMMT/FmmtLib.c | 26 -------------------------- > 2 files changed, 52 deletions(-) >=20 > diff --git a/BaseTools/Source/C/BfmLib/BfmLib.c > b/BaseTools/Source/C/BfmLib/BfmLib.c > index c247cc8e1d..0893356b08 100644 > --- a/BaseTools/Source/C/BfmLib/BfmLib.c > +++ b/BaseTools/Source/C/BfmLib/BfmLib.c > @@ -363,11 +363,9 @@ LibGetFvSize ( > ) { - UINTN BytesRead; UINT32 = Size; > EFI_FV_BLOCK_MAP_ENTRY BlockMap; - BytesRead =3D 0; Size = =3D 0; if > (InputFile =3D=3D NULL || FvSize =3D=3D NULL) {@@ -377,7 +375,6 @@ LibGet= FvSize ( > fseek (InputFile, sizeof (EFI_FIRMWARE_VOLUME_HEADER) - sizeof > (EFI_FV_BLOCK_MAP_ENTRY), SEEK_CUR); do { fread (&BlockMap, sizeof > (EFI_FV_BLOCK_MAP_ENTRY), 1, InputFile);- BytesRead +=3D sizeof > (EFI_FV_BLOCK_MAP_ENTRY); if (BlockMap.NumBlocks !=3D 0) { Siz= e +=3D > BlockMap.NumBlocks * BlockMap.Length;@@ -1032,7 +1029,6 @@ > LibParseSection ( > CHAR16 *UIName; UINT32 UINameSize; BOOLE= AN > HasDepexSection;- UINT32 NumberOfSections; BOOLEAN > IsFfsGenerated; ENCAP_INFO_DATA *LocalEncapData; CHAR8 > *BlankChar;@@ -1058,7 +1054,6 @@ LibParseSection ( > ParsedLength =3D 0; ToolOutputLength =3D 0; = UINameSize > =3D 0;- NumberOfSections =3D 0; UncompressedLength = =3D 0; > CompressedLength =3D 0; CompressionType =3D 0;@@ -= 1116,7 > +1111,6 @@ LibParseSection ( > EncapDataNeedUpdata =3D TRUE; Level ++;- NumberOfSecti= ons ++; > CurrentFv->FfsAttuibutes[*FfsCount].IsLeaf =3D FALSE; @@ -1171,7 +1165,6 = @@ > LibParseSection ( > case EFI_SECTION_COMPRESSION: Level ++;- NumberOfSection= s ++; > EncapDataNeedUpdata =3D TRUE; //@@ -1317,7 +1310,6 @@ > LibParseSection ( > // a GUID defined FV section. // Level ++;- Numbe= rOfSections++; > EncapDataNeedUpdata =3D TRUE; //@@ -1583,7 +1575,6 @@ > LibParseSection ( > //Leaf sections // case EFI_SECTION_RAW:- NumberOfS= ections > ++; CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; if (= !ViewFlag) > { if (!IsFfsGenerated) {@@ -1594,7 +1585,6 @@ LibParseSection ( > break; case EFI_SECTION_PE32:- NumberOfSections ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; if (!ViewFlag)= { if > (!IsFfsGenerated) {@@ -1605,7 +1595,6 @@ LibParseSection ( > break; case EFI_SECTION_PIC:- NumberOfSections ++; = CurrentFv- > >FfsAttuibutes[*FfsCount].Level =3D Level; if (!ViewFlag) { = if > (!IsFfsGenerated) {@@ -1616,7 +1605,6 @@ LibParseSection ( > break; case EFI_SECTION_TE:- NumberOfSections ++; = CurrentFv- > >FfsAttuibutes[*FfsCount].Level =3D Level; if (!ViewFlag) { = if > (!IsFfsGenerated) {@@ -1627,7 +1615,6 @@ LibParseSection ( > break; case EFI_SECTION_COMPATIBILITY16:- NumberOfSectio= ns ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; if (!ViewFlag= ) {@@ - > 1639,7 +1626,6 @@ LibParseSection ( > break; case EFI_SECTION_FREEFORM_SUBTYPE_GUID:- > NumberOfSections ++; CurrentFv->FfsAttuibutes[*FfsCount].Level =3D = Level; > if (!ViewFlag) { if (!IsFfsGenerated) {@@ -1650,27 +1636,22 @@ > LibParseSection ( > break; case EFI_SECTION_VERSION:- NumberOfSections ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; break; cas= e > EFI_SECTION_PEI_DEPEX:- NumberOfSections ++; CurrentFv- > >FfsAttuibutes[*FfsCount].Level =3D Level; HasDepexSection =3D TRUE= ; > break; case EFI_SECTION_DXE_DEPEX:- NumberOfSections ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; HasDepexSectio= n =3D > TRUE; break; case EFI_SECTION_SMM_DEPEX:- NumberOfSections > ++; CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; > HasDepexSection =3D TRUE; break; case EFI_SECTION_USER_INTERFA= CE:- > NumberOfSections ++; CurrentFv->FfsAttuibutes[*FfsCount].Level =3D = Level; > UiSectionLength =3D FvBufExpand3ByteSize (((EFI_USER_INTERFACE_SECTION *) > Ptr)->CommonHeader.Size);@@ -1975,7 +1956,6 @@ LibGetFvInfo ( > ) { EFI_STATUS Status;- UINTN = NumberOfFiles; > BOOLEAN ErasePolarity; UINTN = FvSize; > EFI_FFS_FILE_HEADER2 *CurrentFile;@@ -1983,7 +1963,6 @@ > LibGetFvInfo ( > ENCAP_INFO_DATA *LocalEncapData; > EFI_FIRMWARE_VOLUME_EXT_HEADER *ExtHdrPtr; - NumberOfFiles =3D 0; > Key =3D 0; LocalEncapData =3D NULL; CurrentFile =3D NUL= L;@@ -2147,11 > +2126,6 @@ LibGetFvInfo ( > while (CurrentFile !=3D NULL) { - //- // Increment the number o= f files > counter- //- NumberOfFiles++;- // // Store FFS file Header = information > //diff --git a/BaseTools/Source/C/FMMT/FmmtLib.c > b/BaseTools/Source/C/FMMT/FmmtLib.c > index e1436112ca..20e3e1acfc 100644 > --- a/BaseTools/Source/C/FMMT/FmmtLib.c > +++ b/BaseTools/Source/C/FMMT/FmmtLib.c > @@ -552,11 +552,9 @@ LibGetFvSize ( > ) { - UINTN BytesRead; UINT32 = Size; > EFI_FV_BLOCK_MAP_ENTRY BlockMap; - BytesRead =3D 0; Size = =3D 0; if > (InputFile =3D=3D NULL || FvSize =3D=3D NULL) {@@ -567,7 +565,6 @@ LibGet= FvSize ( > fseek (InputFile, sizeof (EFI_FIRMWARE_VOLUME_HEADER) - sizeof > (EFI_FV_BLOCK_MAP_ENTRY), SEEK_CUR); do { fread (&BlockMap, sizeof > (EFI_FV_BLOCK_MAP_ENTRY), 1, InputFile);- BytesRead +=3D sizeof > (EFI_FV_BLOCK_MAP_ENTRY); if (BlockMap.NumBlocks !=3D 0) { Siz= e +=3D > BlockMap.NumBlocks * BlockMap.Length;@@ -813,7 +810,6 @@ > LibParseSection ( > CHAR16 *UIName; UINT32 UINameSize; BOOLE= AN > HasDepexSection;- UINT32 NumberOfSections; ENCAP_INFO_DAT= A > *LocalEncapData; ENCAP_INFO_DATA *LocalEncapDataTemp; CHAR8 > *BlankChar;@@ -846,7 +842,6 @@ LibParseSection ( > ParsedLength =3D 0; ToolOutputLength =3D 0; = UINameSize > =3D 0;- NumberOfSections =3D 0; UncompressedLength = =3D 0; > CompressedLength =3D 0; CompressionType =3D 0;@@ -= 910,7 +905,6 > @@ LibParseSection ( > HasUiSection =3D TRUE; Level ++;- NumberOfSections ++; > CurrentFv->FfsAttuibutes[*FfsCount].IsLeaf =3D FALSE; CurrentFv- > >FfsAttuibutes[*FfsCount].IsFvStart =3D TRUE;@@ -1021,7 +1015,6 @@ > LibParseSection ( > Level ++; } }- NumberOfSections ++; > EncapDataNeedUpdata =3D TRUE; HasUiSection =3D TRUE;@@ -1211,7 +120= 4,6 > @@ LibParseSection ( > Level ++; } }- NumberOfSections++; > EncapDataNeedUpdata =3D TRUE; HasUiSection =3D TRUE; //@@ -15= 59,7 > +1551,6 @@ LibParseSection ( > //Leaf sections // case EFI_SECTION_RAW:- NumberOfSecti= ons ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; if (!ViewFlag)= { if > (!*IsFfsGenerated) {@@ -1570,7 +1561,6 @@ LibParseSection ( > break; case EFI_SECTION_PE32:- NumberOfSections ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; if (!ViewFlag)= { if > (!*IsFfsGenerated) {@@ -1581,7 +1571,6 @@ LibParseSection ( > break; case EFI_SECTION_PIC:- NumberOfSections ++; = CurrentFv- > >FfsAttuibutes[*FfsCount].Level =3D Level; if (!ViewFlag) { = if > (!*IsFfsGenerated) {@@ -1592,7 +1581,6 @@ LibParseSection ( > break; case EFI_SECTION_TE:- NumberOfSections ++; = CurrentFv- > >FfsAttuibutes[*FfsCount].Level =3D Level; if (!ViewFlag) { = if > (!*IsFfsGenerated) {@@ -1603,7 +1591,6 @@ LibParseSection ( > break; case EFI_SECTION_COMPATIBILITY16:- NumberOfSectio= ns ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; if (!ViewFlag)= { if > (!*IsFfsGenerated) {@@ -1614,7 +1601,6 @@ LibParseSection ( > break; case EFI_SECTION_FREEFORM_SUBTYPE_GUID:- > NumberOfSections ++; CurrentFv->FfsAttuibutes[*FfsCount].Level =3D = Level; > if (!ViewFlag) { if (!*IsFfsGenerated) {@@ -1625,11 +1611,9 @@ > LibParseSection ( > break; case EFI_SECTION_VERSION:- NumberOfSections ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; break; cas= e > EFI_SECTION_PEI_DEPEX:- NumberOfSections ++; CurrentFv- > >FfsAttuibutes[*FfsCount].Level =3D Level; HasDepexSection =3D TRUE= ; > CurrentFv->FfsAttuibutes[*FfsCount].PeiDepex =3D malloc (SectionLength);@= @ - > 1637,7 +1621,6 @@ LibParseSection ( > CurrentFv->FfsAttuibutes[*FfsCount].PeiDepexLen =3D SectionLength; > break; case EFI_SECTION_DXE_DEPEX:- NumberOfSections ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; HasDepexSectio= n =3D > TRUE; CurrentFv->FfsAttuibutes[*FfsCount].DxeDepex =3D malloc > (SectionLength);@@ -1645,7 +1628,6 @@ LibParseSection ( > CurrentFv->FfsAttuibutes[*FfsCount].DxeDepexLen =3D SectionLength; > break; case EFI_SECTION_SMM_DEPEX:- NumberOfSections ++; > CurrentFv->FfsAttuibutes[*FfsCount].Level =3D Level; HasDepexSectio= n =3D > TRUE; CurrentFv->FfsAttuibutes[*FfsCount].SmmDepex =3D malloc > (SectionLength);@@ -1655,7 +1637,6 @@ LibParseSection ( > case EFI_SECTION_USER_INTERFACE: HasUiSection =3D TRUE;- > NumberOfSections ++; CurrentFv->FfsAttuibutes[*FfsCount].Level =3D = Level; > UiSectionLength =3D GetLength (((EFI_USER_INTERFACE_SECTION *) Ptr)- > >CommonHeader.Size);@@ -2186,7 +2167,6 @@ LibGetFvInfo ( > ) { EFI_STATUS Status;- UINTN = NumberOfFiles; > BOOLEAN ErasePolarity; UINTN = FvSize; > EFI_FFS_FILE_HEADER2 *CurrentFile;@@ -2196,7 +2176,6 @@ > LibGetFvInfo ( > EFI_FIRMWARE_VOLUME_HEADER *FvHdr; UINT8 PreFvI= d; - > NumberOfFiles =3D 0; Key =3D 0; LocalEncapData =3D NULL; = CurrentFile =3D > NULL;@@ -2382,11 +2361,6 @@ LibGetFvInfo ( > while (CurrentFile !=3D NULL) { - //- // Increment the number o= f files > counter- //- NumberOfFiles++;- // // Store FFS file Header = information > //-- > 2.40.1.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#119904): https://edk2.groups.io/g/devel/message/119904 Mute This Topic: https://groups.io/mt/107051142/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-