Cc: Liming Gao <liming....@intel.com> Cc: Yonghong Zhu <yonghong....@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu <hao.a...@intel.com> --- BaseTools/Source/C/LzmaCompress/LzmaCompress.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/BaseTools/Source/C/LzmaCompress/LzmaCompress.c b/BaseTools/Source/C/LzmaCompress/LzmaCompress.c index 1de07a3..ee6e1fe 100644 --- a/BaseTools/Source/C/LzmaCompress/LzmaCompress.c +++ b/BaseTools/Source/C/LzmaCompress/LzmaCompress.c @@ -5,7 +5,7 @@ LzmaUtil.c -- Test application for LZMA compression 2008-11-23 : Igor Pavlov : Public domain - Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR> + Copyright (c) 2006 - 2016, Intel Corporation. All rights reserved.<BR> This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License which accompanies this distribution. The full text of the license may be found at @@ -333,8 +333,10 @@ int main2(int numArgs, const char *args[], char *rs) if (InFile_Open(&inStream.file, inputFile) != 0) return PrintError(rs, "Can not open input file"); - if (OutFile_Open(&outStream.file, outputFile) != 0) + if (OutFile_Open(&outStream.file, outputFile) != 0) { + File_Close(&inStream.file); return PrintError(rs, "Can not open output file"); + } File_GetLength(&inStream.file, &fileSize); -- 1.9.5.msysgit.0 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel