Fix the type-cast between UINT32 & UINTN
authorqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Wed, 8 Aug 2007 15:00:43 +0000 (15:00 +0000)
committerqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Wed, 8 Aug 2007 15:00:43 +0000 (15:00 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@3575 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Core/Dxe/SectionExtraction/CoreSectionExtraction.c

index b86f273..70c71c6 100644 (file)
@@ -262,7 +262,7 @@ Returns:
 {\r
   EFI_STATUS                         Status;\r
   EFI_GUID                           **DecompressGuidList;\r
-  UINT32                             DecompressMethodNumber;\r
+  UINT                             DecompressMethodNumber;\r
 \r
   //\r
   // Install SEP to a new handle\r
@@ -1474,6 +1474,7 @@ CustomDecompressExtractSection (
 {\r
   EFI_STATUS      Status;\r
   UINT8           *ScratchBuffer;\r
+  UINT32          DestinationSize;\r
   UINT32          ScratchSize;\r
   UINT32          SectionLength;  \r
   \r
@@ -1492,7 +1493,7 @@ CustomDecompressExtractSection (
              (GUID *) ((UINT8 *) InputSection + sizeof (EFI_COMMON_SECTION_HEADER)),\r
              (UINT8 *) InputSection + sizeof (EFI_GUID_DEFINED_SECTION),\r
              SectionLength - sizeof (EFI_GUID_DEFINED_SECTION),\r
-             OutputSize,\r
+             &DestinationSize,\r
              &ScratchSize\r
              );\r
   if (EFI_ERROR (Status)) {\r
@@ -1513,6 +1514,7 @@ CustomDecompressExtractSection (
   //\r
   // Allocate destination buffer\r
   //\r
+  *OutputSize = (UINTN) DestinationSize;\r
   *OutputBuffer = CoreAllocateBootServicesPool (*OutputSize);\r
   if (*OutputBuffer == NULL) {\r
     CoreFreePool (ScratchBuffer);\r