]> git.proxmox.com Git - mirror_edk2.git/commitdiff
BaseTools/GenSec: Fix potential memory leak
authorHao Wu <hao.a.wu@intel.com>
Mon, 18 Dec 2017 07:59:53 +0000 (15:59 +0800)
committerHao Wu <hao.a.wu@intel.com>
Mon, 25 Dec 2017 01:54:48 +0000 (09:54 +0800)
Cc: Yonghong Zhu <yonghong.zhu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Hao Wu <hao.a.wu@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
BaseTools/Source/C/GenSec/GenSec.c

index 5545f12b74a8d2c15a70950ea57e45ce92a7cadb..01d3bc4448089fdd30543e7f567346bf82217697 100644 (file)
@@ -1670,7 +1670,11 @@ Finish:
   if (OutFile != NULL) {\r
     fclose (OutFile);\r
   }\r
-  \r
+\r
+  if (DummyFileBuffer != NULL) {\r
+    free (DummyFileBuffer);\r
+  }\r
+\r
   VerboseMsg ("%s tool done with return code is 0x%x.", UTILITY_NAME, GetUtilityStatus ());\r
 \r
   return GetUtilityStatus ();\r