From nobody Sat Nov 2 16:20:05 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 1487676979812406.95296217773125; Tue, 21 Feb 2017 03:36:19 -0800 (PST) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 16A388222E; Tue, 21 Feb 2017 03:36:15 -0800 (PST) Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) (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 225BC8222E for ; Tue, 21 Feb 2017 03:36:14 -0800 (PST) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 21 Feb 2017 03:36:14 -0800 Received: from shwdeopenpsi014.ccr.corp.intel.com ([10.239.9.13]) by fmsmga006.fm.intel.com with ESMTP; 21 Feb 2017 03:36:12 -0800 X-Original-To: edk2-devel@lists.01.org X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.35,189,1484035200"; d="scan'208";a="68323655" From: Hao Wu To: edk2-devel@lists.01.org Date: Tue, 21 Feb 2017 19:35:34 +0800 Message-Id: <1487676934-12984-8-git-send-email-hao.a.wu@intel.com> X-Mailer: git-send-email 1.9.5.msysgit.0 In-Reply-To: <1487676934-12984-1-git-send-email-hao.a.wu@intel.com> References: <1487676934-12984-1-git-send-email-hao.a.wu@intel.com> Subject: [edk2] [PATCH 7/7] MdePkg/BasePrintLib: Add deprecated flag for APIs [A|U]ValueToString 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: Hao Wu , Michael Kinney , Jiewen Yao , Liming Gao 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" Cc: Jiewen Yao Cc: Liming Gao Cc: Michael Kinney Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu --- MdePkg/Include/Library/PrintLib.h | 12 ++++++++++++ MdePkg/Library/BasePrintLib/PrintLib.c | 12 ++++++++++++ 2 files changed, 24 insertions(+) diff --git a/MdePkg/Include/Library/PrintLib.h b/MdePkg/Include/Library/Pri= ntLib.h index 8c11dab..9fe3609 100644 --- a/MdePkg/Include/Library/PrintLib.h +++ b/MdePkg/Include/Library/PrintLib.h @@ -491,7 +491,11 @@ UnicodeSPrintAsciiFormat ( ... ); =20 +#ifndef DISABLE_NEW_DEPRECATED_INTERFACES + /** + [ATTENTION] This function is deprecated for security reason. + Converts a decimal value to a Null-terminated Unicode string. =20 Converts the decimal number specified by Value to a Null-terminated Unic= ode=20 @@ -541,6 +545,8 @@ UnicodeValueToString ( IN UINTN Width ); =20 +#endif + /** Converts a decimal value to a Null-terminated Unicode string. =20 @@ -882,7 +888,11 @@ AsciiSPrintUnicodeFormat ( ... ); =20 +#ifndef DISABLE_NEW_DEPRECATED_INTERFACES + /** + [ATTENTION] This function is deprecated for security reason. + Converts a decimal value to a Null-terminated ASCII string. =20 Converts the decimal number specified by Value to a Null-terminated ASCI= I string=20 @@ -931,6 +941,8 @@ AsciiValueToString ( IN UINTN Width ); =20 +#endif + /** Converts a decimal value to a Null-terminated Ascii string. =20 diff --git a/MdePkg/Library/BasePrintLib/PrintLib.c b/MdePkg/Library/BasePr= intLib/PrintLib.c index 221b52e..7453e95 100644 --- a/MdePkg/Library/BasePrintLib/PrintLib.c +++ b/MdePkg/Library/BasePrintLib/PrintLib.c @@ -349,7 +349,11 @@ UnicodeSPrintAsciiFormat ( return NumberOfPrinted; } =20 +#ifndef DISABLE_NEW_DEPRECATED_INTERFACES + /** + [ATTENTION] This function is deprecated for security reason. + Converts a decimal value to a Null-terminated Unicode string. =20 Converts the decimal number specified by Value to a Null-terminated Unic= ode=20 @@ -403,6 +407,8 @@ UnicodeValueToString ( return BasePrintLibConvertValueToString ((CHAR8 *)Buffer, Flags, Value, = Width, 2); } =20 +#endif + /** Converts a decimal value to a Null-terminated Unicode string. =20 @@ -781,7 +787,11 @@ AsciiSPrintUnicodeFormat ( } =20 =20 +#ifndef DISABLE_NEW_DEPRECATED_INTERFACES + /** + [ATTENTION] This function is deprecated for security reason. + Converts a decimal value to a Null-terminated ASCII string. =20 Converts the decimal number specified by Value to a Null-terminated ASCI= I string=20 @@ -833,6 +843,8 @@ AsciiValueToString ( return BasePrintLibConvertValueToString (Buffer, Flags, Value, Width, 1); } =20 +#endif + /** Converts a decimal value to a Null-terminated Ascii string. =20 --=20 1.9.5.msysgit.0 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel