diff options
author | Jeff Westfahl <jeff.westfahl@ni.com> | 2017-05-13 04:41:40 +0800 |
---|---|---|
committer | Guo Mang <mang.guo@intel.com> | 2017-07-12 11:24:52 +0800 |
commit | 898dfba71965d11c350e349828ebddddb9090353 (patch) | |
tree | bab56df48d27b6c1a05d8ac2f9fc5400dde57178 /Core/ShellPkg | |
parent | dd8ee7179e1aa88ee5ca289faebdacaaf8809bb8 (diff) | |
download | edk2-platforms-898dfba71965d11c350e349828ebddddb9090353.tar.xz |
ShellPkg/UefiShellLib: Check correct variable for NULL
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Jaben Carsey <jaben.carsey@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Jeff Westfahl <jeff.westfahl@ni.com>
Reviewed-by: Jaben Carsey <jaben.carsey@intel.com>
(cherry picked from commit 5220897839dd583e9d1f749fb4d8196ff86ccc8b)
Diffstat (limited to 'Core/ShellPkg')
-rw-r--r-- | Core/ShellPkg/Library/UefiShellLib/UefiShellLib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Core/ShellPkg/Library/UefiShellLib/UefiShellLib.c b/Core/ShellPkg/Library/UefiShellLib/UefiShellLib.c index 55e8a67ac4..0f37886956 100644 --- a/Core/ShellPkg/Library/UefiShellLib/UefiShellLib.c +++ b/Core/ShellPkg/Library/UefiShellLib/UefiShellLib.c @@ -702,7 +702,7 @@ ShellOpenFileByName( // Create the directory to create the file in
//
FileNameCopy = AllocateCopyPool (StrSize (FileName), FileName);
- if (FileName == NULL) {
+ if (FileNameCopy == NULL) {
return (EFI_OUT_OF_RESOURCES);
}
PathCleanUpDirectories (FileNameCopy);
|