From 9f4048f7f8cd4b6bd5eee0f0c4bfd4eb6926a536 Mon Sep 17 00:00:00 2001 From: Hao Wu Date: Wed, 18 Jan 2017 10:31:02 +0800 Subject: MdeModulePkg: Replace [Ascii|Unicode]ValueToString It is the follow up of commits 51f0ceb..9e32e97 to replace AsciiValueToString/UnicodeValueToString with AsciiValueToStringS/UnicodeValueToStringS. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu Reviewed-by: Star Zeng --- MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'MdeModulePkg/Universal/CapsuleRuntimeDxe') diff --git a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c b/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c index ed8820a..216798d 100644 --- a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c +++ b/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c @@ -4,7 +4,7 @@ It installs the Capsule Architectural Protocol defined in PI1.0a to signify the capsule runtime services are ready. -Copyright (c) 2006 - 2015, Intel Corporation. All rights reserved.
+Copyright (c) 2006 - 2017, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at @@ -205,7 +205,13 @@ UpdateCapsule ( StrCpyS (CapsuleVarName, sizeof(CapsuleVarName)/sizeof(CHAR16), EFI_CAPSULE_VARIABLE_NAME); TempVarName = CapsuleVarName + StrLen (CapsuleVarName); if (mTimes > 0) { - UnicodeValueToString (TempVarName, 0, mTimes, 0); + UnicodeValueToStringS ( + TempVarName, + sizeof (CapsuleVarName) - ((UINTN)TempVarName - (UINTN)CapsuleVarName), + 0, + mTimes, + 0 + ); } // -- cgit v1.1