From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.151; helo=mga17.intel.com; envelope-from=liming.gao@intel.com; receiver=edk2-devel@lists.01.org Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) (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 8BE7A207E36C8 for ; Mon, 28 May 2018 21:35:05 -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 fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 28 May 2018 21:35:05 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,455,1520924400"; d="scan'208";a="59896555" Received: from fmsmsx106.amr.corp.intel.com ([10.18.124.204]) by orsmga001.jf.intel.com with ESMTP; 28 May 2018 21:34:55 -0700 Received: from FMSMSX109.amr.corp.intel.com (10.18.116.9) by FMSMSX106.amr.corp.intel.com (10.18.124.204) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 28 May 2018 21:33:54 -0700 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by fmsmsx109.amr.corp.intel.com (10.18.116.9) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 28 May 2018 20:36:38 -0700 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.87]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.82]) with mapi id 14.03.0319.002; Tue, 29 May 2018 11:36:37 +0800 From: "Gao, Liming" To: Marvin H?user , "edk2-devel@lists.01.org" CC: "Zeng, Star" Thread-Topic: [edk2] [Patch 0/3] Use comparison logic to check UINTN parameter in GetBestLanguage API Thread-Index: AQHT9laidpoqG6t91UGUjdIzcOYxhaREP0GAgAAExgCAActmIA== Date: Tue, 29 May 2018 03:36:37 +0000 Message-ID: <4A89E2EF3DFEDB4C8BFDE51014F606A14E28DC77@SHSMSX104.ccr.corp.intel.com> References: <1527492652-17544-1-git-send-email-liming.gao@intel.com> <0C09AFA07DD0434D9E2A0C6AEB0483103BB3EC98@shsmsx102.ccr.corp.intel.com> In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [Patch 0/3] Use comparison logic to check UINTN parameter in GetBestLanguage API X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 May 2018 04:35:05 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Marvin: Current solution is to keep max compatibility.=20 Thanks Liming >-----Original Message----- >From: Marvin H?user [mailto:Marvin.Haeuser@outlook.com] >Sent: Monday, May 28, 2018 4:11 PM >To: edk2-devel@lists.01.org >Cc: Zeng, Star ; Gao, Liming >Subject: RE: [edk2] [Patch 0/3] Use comparison logic to check UINTN >parameter in GetBestLanguage API > >Hey Star and Liming, > >May I propose re-considering the introduction of a third named parameter t= o >reflect the first Language passed? >This would 1) have the advantage that the BOOLEAN parameter can remain as >is, which increases readability and >2) require at least two parameters related to the language list passed. Ha= ving >to write "NULL, NULL" is way more obvious than just having to write "NULL" >when (accidentally?) not passing any language. > >And error caused by this change would be calls that do not pass an expecte= d >amount of parameters for the call to make sense. > >Thanks, >Marvin. > >> -----Original Message----- >> From: edk2-devel On Behalf Of Zeng, >> Star >> Sent: Monday, May 28, 2018 9:54 AM >> To: Gao, Liming ; edk2-devel@lists.01.org >> Cc: Zeng, Star >> Subject: Re: [edk2] [Patch 0/3] Use comparison logic to check UINTN >> parameter in GetBestLanguage API >> >> Reviewed-by: Star Zeng >> >> -----Original Message----- >> From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of >> Liming Gao >> Sent: Monday, May 28, 2018 3:31 PM >> To: edk2-devel@lists.01.org >> Subject: [edk2] [Patch 0/3] Use comparison logic to check UINTN paramete= r >> in GetBestLanguage API >> >> Liming Gao (3): >> MdePkg UefiLib: Use comparison logic to check UINTN parameter >> IntelFrameworkPkg UefiLib: Use comparison logic to check UINTN >> parameter >> MdeModulePkg Variable: Use comparison logic to check UINTN parameter >> >> IntelFrameworkPkg/Library/FrameworkUefiLib/UefiLib.c | 6 +++--- >> MdeModulePkg/Universal/Variable/EmuRuntimeDxe/EmuVariable.c | 8 >> ++++---- >> MdeModulePkg/Universal/Variable/RuntimeDxe/Variable.c | 8 ++++---= - >> MdePkg/Library/UefiLib/UefiLib.c | 6 +++--- >> 4 files changed, 14 insertions(+), 14 deletions(-) >> >> -- >> 2.8.0.windows.1 >> >> _______________________________________________ >> edk2-devel mailing list >> edk2-devel@lists.01.org >> https://lists.01.org/mailman/listinfo/edk2-devel >> _______________________________________________ >> edk2-devel mailing list >> edk2-devel@lists.01.org >> https://lists.01.org/mailman/listinfo/edk2-devel