From 75a5e2ef4e3b3a3c1d25ef0be3621edf541237c3 Mon Sep 17 00:00:00 2001 From: Jaben Carsey Date: Fri, 10 Jan 2014 16:42:45 +0000 Subject: [PATCH] ShellPkg: remove potential memory leak with new apps on old shell This pointer never gets free when running new apps on the old shell. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Jaben Carsey Reviewed-by: Ruiyu Ni git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@15095 6f19259b-4bc3-4df7-8a09-765794883524 --- ShellPkg/Library/UefiShellLib/UefiShellLib.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ShellPkg/Library/UefiShellLib/UefiShellLib.c b/ShellPkg/Library/UefiShellLib/UefiShellLib.c index 7b34aff2f8..9b58786756 100644 --- a/ShellPkg/Library/UefiShellLib/UefiShellLib.c +++ b/ShellPkg/Library/UefiShellLib/UefiShellLib.c @@ -1,7 +1,7 @@ /** @file Provides interface to shell functionality for shell commands and applications. - Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.
+ Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.
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 @@ -1598,6 +1598,7 @@ ShellCloseFileMetaArg ( FreePool(((EFI_SHELL_FILE_INFO_NO_CONST*)Node)->Info); FreePool((EFI_SHELL_FILE_INFO_NO_CONST*)Node); } + SHELL_FREE_NON_NULL(*ListHead); return EFI_SUCCESS; } -- 2.39.2