ShellPkg: Fix memory leak in function'ShellCommandConsistMappingInitialize'.
authorYao Jiewen <Jiewen.Yao@intel.com>
Fri, 25 Dec 2015 01:46:02 +0000 (01:46 +0000)
committershenshushi <shenshushi@Edk2>
Fri, 25 Dec 2015 01:46:02 +0000 (01:46 +0000)
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Yao Jiewen <Jiewen.Yao@intel.com>
Reviewed-by: Qiu Shumin <shumin.qiu@intel.com>
Reviewed-by: Ruiyu Ni <ruiyu.ni@intel.com>
git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@19528 6f19259b-4bc3-4df7-8a09-765794883524

ShellPkg/Library/UefiShellCommandLib/ConsistMapping.c

index 86e8dc59a8951bab39356886c7ec2428e32d6110..41754dd905d699bae30c3d304a156517f0c359d1 100644 (file)
@@ -1401,6 +1401,7 @@ ShellCommandConsistMappingInitialize (
                                     (VOID **)&SimpleFileSystem\r
                                     );\r
       if (EFI_ERROR(Status)) {\r
+        FreePool (HIDevicePath);\r
         continue;\r
       }\r
     }\r