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>
This commit is contained in:
@ -702,7 +702,7 @@ ShellOpenFileByName(
|
|||||||
// Create the directory to create the file in
|
// Create the directory to create the file in
|
||||||
//
|
//
|
||||||
FileNameCopy = AllocateCopyPool (StrSize (FileName), FileName);
|
FileNameCopy = AllocateCopyPool (StrSize (FileName), FileName);
|
||||||
if (FileName == NULL) {
|
if (FileNameCopy == NULL) {
|
||||||
return (EFI_OUT_OF_RESOURCES);
|
return (EFI_OUT_OF_RESOURCES);
|
||||||
}
|
}
|
||||||
PathCleanUpDirectories (FileNameCopy);
|
PathCleanUpDirectories (FileNameCopy);
|
||||||
|
Reference in New Issue
Block a user