MdeModulePkg DxeCapsuleLibFmp: Free HandleBuffer after it is used
authorStar Zeng <star.zeng@intel.com>
Mon, 30 Jul 2018 06:47:28 +0000 (14:47 +0800)
committerStar Zeng <star.zeng@intel.com>
Wed, 1 Aug 2018 02:15:19 +0000 (10:15 +0800)
Cc: Jiewen Yao <jiewen.yao@intel.com>
Cc: Michael D Kinney <michael.d.kinney@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Star Zeng <star.zeng@intel.com>
Reviewed-by: Jiewen Yao <jiewen.yao@intel.com>
MdeModulePkg/Library/DxeCapsuleLibFmp/DxeCapsuleLib.c

index d4026dd..8584827 100644 (file)
@@ -610,6 +610,8 @@ DumpAllFmpInfo (
     FreePool(FmpImageInfoBuf);\r
   }\r
 \r
+  FreePool (HandleBuffer);\r
+\r
   return ;\r
 }\r
 \r
@@ -777,6 +779,8 @@ GetFmpHandleBufferByType (
     FreePool(FmpImageInfoBuf);\r
   }\r
 \r
+  FreePool (HandleBuffer);\r
+\r
   if (MatchedNumberOfHandles == 0) {\r
     return EFI_NOT_FOUND;\r
   }\r