ShellPkg Build failure of AllocateZeroPool usage. This patch updates AllocateZeroPool() to AllocateCopyPool()
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Gao, Liming <liming.gao@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16007 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@ -1165,7 +1165,7 @@ ShellCommandAddMapItemAndUpdatePath(
|
|||||||
Status = EFI_OUT_OF_RESOURCES;
|
Status = EFI_OUT_OF_RESOURCES;
|
||||||
} else {
|
} else {
|
||||||
MapListNode->Flags = Flags;
|
MapListNode->Flags = Flags;
|
||||||
MapListNode->MapName = AllocateZeroPool(StrSize(Name), Name);
|
MapListNode->MapName = AllocateCopyPool(StrSize(Name), Name);
|
||||||
MapListNode->DevicePath = DuplicateDevicePath(DevicePath);
|
MapListNode->DevicePath = DuplicateDevicePath(DevicePath);
|
||||||
if ((MapListNode->MapName == NULL) || (MapListNode->DevicePath == NULL)){
|
if ((MapListNode->MapName == NULL) || (MapListNode->DevicePath == NULL)){
|
||||||
Status = EFI_OUT_OF_RESOURCES;
|
Status = EFI_OUT_OF_RESOURCES;
|
||||||
|
Reference in New Issue
Block a user