X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=blobdiff_plain;f=MdeModulePkg%2FCore%2FDxe%2FSectionExtraction%2FCoreSectionExtraction.c;h=de719f3e2e9c1d4036fefc27c1c60fce59816934;hp=b86f273f33898f5bcd1fa878fc3e97b03b8775c6;hb=88ce0209fc1f4dd183c52095d2c186f31633bad5;hpb=d8c79a815f9e993b741ec38cd39498e674e1739e diff --git a/MdeModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c b/MdeModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c index b86f273f33..de719f3e2e 100644 --- a/MdeModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c +++ b/MdeModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c @@ -1474,6 +1474,7 @@ CustomDecompressExtractSection ( { EFI_STATUS Status; UINT8 *ScratchBuffer; + UINT32 DestinationSize; UINT32 ScratchSize; UINT32 SectionLength; @@ -1492,7 +1493,7 @@ CustomDecompressExtractSection ( (GUID *) ((UINT8 *) InputSection + sizeof (EFI_COMMON_SECTION_HEADER)), (UINT8 *) InputSection + sizeof (EFI_GUID_DEFINED_SECTION), SectionLength - sizeof (EFI_GUID_DEFINED_SECTION), - OutputSize, + &DestinationSize, &ScratchSize ); if (EFI_ERROR (Status)) { @@ -1513,6 +1514,7 @@ CustomDecompressExtractSection ( // // Allocate destination buffer // + *OutputSize = (UINTN) DestinationSize; *OutputBuffer = CoreAllocateBootServicesPool (*OutputSize); if (*OutputBuffer == NULL) { CoreFreePool (ScratchBuffer);