回复: [edk2-devel] [PATCH 1/1] MdeModulePkg: Fix a typo


gaoliming
 

Shuzhen:

 The patch title can be MdeModulePkg DxeMain: Fix the typo in local variable name.

 

  With this change, Reviewed-by: Liming Gao <gaoliming@...>

 

Thanks

Liming

发件人: devel@edk2.groups.io <devel@edk2.groups.io> 代表 zhangshuzhen@...
发送时间: 202261 10:21
收件人: devel@edk2.groups.io
主题: [edk2-devel] [PATCH 1/1] MdeModulePkg: Fix a typo

 

Correctly write 'DstBufAllocated' in CoreLoadPeImage().

Signed-off-by: Zhang Shuzhen <zhangshuzhen@...>
---
 MdeModulePkg/Core/Dxe/Image/Image.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/MdeModulePkg/Core/Dxe/Image/Image.c b/MdeModulePkg/Core/Dxe/Image/Image.c
index 68bde5c15c..5bdf96b52c 100644
--- a/MdeModulePkg/Core/Dxe/Image/Image.c
+++ b/MdeModulePkg/Core/Dxe/Image/Image.c
@@ -581,7 +581,7 @@ CoreLoadPeImage (
   )
 {
   EFI_STATUS  Status;
-  BOOLEAN     DstBufAlocated;
+  BOOLEAN     DstBufAllocated;
   UINTN       Size;
 
   ZeroMem (&Image->ImageContext, sizeof (Image->ImageContext));
@@ -636,7 +636,7 @@ CoreLoadPeImage (
   //
   // Allocate memory of the correct memory type aligned on the required image boundary
   //
-  DstBufAlocated = FALSE;
+  DstBufAllocated = FALSE;
   if (DstBuffer == 0) {
     //
     // Allocate Destination Buffer as caller did not pass it in
@@ -702,7 +702,7 @@ CoreLoadPeImage (
       return Status;
     }
 
-    DstBufAlocated = TRUE;
+    DstBufAllocated = TRUE;
   } else {
     //
     // Caller provided the destination buffer
@@ -884,7 +884,7 @@ Done:
   // Free memory.
   //
 
-  if (DstBufAlocated) {
+  if (DstBufAllocated) {
     CoreFreePages (Image->ImageContext.ImageAddress, Image->NumberOfPages);
     Image->ImageContext.ImageAddress = 0;
     Image->ImageBasePage             = 0;
--
2.36.1

Join devel@edk2.groups.io to automatically receive all group messages.