summaryrefslogtreecommitdiffstats
path: root/BaseTools
diff options
context:
space:
mode:
authorHao Wu <hao.a.wu@intel.com>2016-10-11 15:57:13 +0800
committerHao Wu <hao.a.wu@intel.com>2016-11-08 16:38:12 +0800
commit2a9afe80c3390d2f3540fbb461bb398e49159838 (patch)
treeae688d9011d81d9a28ecc503ba9b992f19a1cff6 /BaseTools
parent4d32be8888f4b7d8e337259fe1a5afd71b6b0046 (diff)
downloadedk2-2a9afe80c3390d2f3540fbb461bb398e49159838.tar.gz
edk2-2a9afe80c3390d2f3540fbb461bb398e49159838.tar.bz2
edk2-2a9afe80c3390d2f3540fbb461bb398e49159838.zip
BaseTools/VolInfo: Fix file handles not being closed
Cc: Liming Gao <liming.gao@intel.com> Cc: Yonghong Zhu <yonghong.zhu@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
Diffstat (limited to 'BaseTools')
-rw-r--r--BaseTools/Source/C/VolInfo/VolInfo.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/BaseTools/Source/C/VolInfo/VolInfo.c b/BaseTools/Source/C/VolInfo/VolInfo.c
index 312d33221b..07840bf669 100644
--- a/BaseTools/Source/C/VolInfo/VolInfo.c
+++ b/BaseTools/Source/C/VolInfo/VolInfo.c
@@ -2191,6 +2191,7 @@ Returns:
//
GPtr = malloc (sizeof (GUID_TO_BASENAME));
if (GPtr == NULL) {
+ fclose (Fptr);
return EFI_OUT_OF_RESOURCES;
}