mirror of https://github.com/acidanthera/audk.git
Remove Size==0 branch in SmmAllocatePool()
The background is : The SmmMemoryAllocationLib of one of the instance of MemoryAllocation library class. As in MdePkg comment for AllocatePool() : “If AllocationSize is 0, then a valid buffer of 0 size is returned.”,the SMM library implements AllocatePool by SMST service SmmAllocatePool which does NOT support the zero size. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10171 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
1b14ec40bb
commit
1fc17d768f
|
@ -224,11 +224,6 @@ SmmAllocatePool (
|
|||
return EFI_INVALID_PARAMETER;
|
||||
}
|
||||
|
||||
if (Size == 0) {
|
||||
*Buffer = NULL;
|
||||
return EFI_SUCCESS;
|
||||
}
|
||||
|
||||
Size += sizeof (*PoolHdr);
|
||||
if (Size > MAX_POOL_SIZE) {
|
||||
Size = EFI_SIZE_TO_PAGES (Size);
|
||||
|
|
Loading…
Reference in New Issue