From: rsun3 Date: Mon, 4 May 2009 08:51:40 +0000 (+0000) Subject: Fix a bug in UefiHiiLib. The size for allocating a buffer is StrSize instead of StrLen. X-Git-Tag: edk2-stable201903~18031 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=f580c1bd27953e9544771c4a388abd79d3394a13;hp=b4e3c5a4b6391838f6bcc16d24ba503cb7ce1c03 Fix a bug in UefiHiiLib. The size for allocating a buffer is StrSize instead of StrLen. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8235 6f19259b-4bc3-4df7-8a09-765794883524 --- diff --git a/MdeModulePkg/Library/UefiHiiLib/HiiString.c b/MdeModulePkg/Library/UefiHiiLib/HiiString.c index f6569754b2..b61a9958d0 100644 --- a/MdeModulePkg/Library/UefiHiiLib/HiiString.c +++ b/MdeModulePkg/Library/UefiHiiLib/HiiString.c @@ -80,7 +80,7 @@ HiiSetString ( // // Allocate a copy of the SupportLanguages string that passed in // - AllocatedLanguages = AllocateCopyPool (AsciiStrLen (SupportedLanguages), SupportedLanguages); + AllocatedLanguages = AllocateCopyPool (AsciiStrSize (SupportedLanguages), SupportedLanguages); } //