mirror of https://github.com/acidanthera/audk.git
ShellPkg: Refine code style to avoid potential uninitialized local variable.
Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Qiu Shumin <shumin.qiu@intel.com> Reviewed-by: Jaben Carsey <Jaben.carsey@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@16146 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
ee1c2b77f4
commit
715096c244
|
@ -313,6 +313,7 @@ ValidateAndCopyFiles(
|
|||
ShellStatus = SHELL_SUCCESS;
|
||||
PathSize = 0;
|
||||
Cwd = ShellGetCurrentDir(NULL);
|
||||
CleanFilePathStr = NULL;
|
||||
|
||||
ASSERT(FileList != NULL);
|
||||
ASSERT(DestDir != NULL);
|
||||
|
|
|
@ -278,6 +278,7 @@ ValidateAndMoveFiles(
|
|||
DestPath = NULL;
|
||||
Cwd = ShellGetCurrentDir(NULL);
|
||||
Response = *Resp;
|
||||
CleanFilePathStr = NULL;
|
||||
|
||||
Status = ShellLevel2StripQuotes (DestDir, &CleanFilePathStr);
|
||||
if (EFI_ERROR (Status)) {
|
||||
|
|
|
@ -1502,6 +1502,8 @@ ShellOpenFileMetaArg (
|
|||
ASSERT(Arg != NULL);
|
||||
ASSERT(ListHead != NULL);
|
||||
|
||||
CleanFilePathStr = NULL;
|
||||
|
||||
Status = InternalShellStripQuotes (Arg, &CleanFilePathStr);
|
||||
if (EFI_ERROR (Status)) {
|
||||
return Status;
|
||||
|
|
Loading…
Reference in New Issue