X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=MdeModulePkg%2FUniversal%2FCapsuleRuntimeDxe%2FCapsuleService.c;h=216798d1617e07ecf0ca7d5cc2e150259da2ad95;hp=ed8820a8f714195187d469a09c3b9378000741f0;hb=9f4048f7f8cd4b6bd5eee0f0c4bfd4eb6926a536;hpb=0438f5e287fa40c7aa143c3a151c5e5c743411b3 diff --git a/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c b/MdeModulePkg/Universal/CapsuleRuntimeDxe/CapsuleService.c index ed8820a8f7..216798d161 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 + ); } //