Revision: 18491
http://sourceforge.net/p/edk2/code/18491
Author: shenshushi
Date: 2015-09-17 01:42:59 +0000 (Thu, 17 Sep 2015)
Log Message:
-----------
ShellPkg: Fix Shell fail when execute command in ShellProtocol.Execute().
When execute a command with tailing blank spaces in ShellProtocol.Execute()
Shell will fail.
This patch move the TrimSpaces operation into ParseCommandLineToArgs function
to fix the problem.
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Yang Jadis <[email protected]>
Signed-off-by: Qiu Shumin <[email protected]>
Reviewed-by: Jaben Carsey <[email protected]>
Modified Paths:
--------------
trunk/edk2/ShellPkg/Application/Shell/ShellParametersProtocol.c
Modified: trunk/edk2/ShellPkg/Application/Shell/ShellParametersProtocol.c
===================================================================
--- trunk/edk2/ShellPkg/Application/Shell/ShellParametersProtocol.c
2015-09-17 01:20:37 UTC (rev 18490)
+++ trunk/edk2/ShellPkg/Application/Shell/ShellParametersProtocol.c
2015-09-17 01:42:59 UTC (rev 18491)
@@ -206,6 +206,7 @@
return (EFI_SUCCESS);
}
+ TrimSpaces(&(CHAR16*)CommandLine);
Size = StrSize(CommandLine);
TempParameter = AllocateZeroPool(Size);
if (TempParameter == NULL) {
@@ -359,7 +360,6 @@
//
// Populate Argc and Argv
//
- TrimSpaces (&FullCommandLine);
Status = ParseCommandLineToArgs(FullCommandLine,
&(*NewShellParameters)->Argv,
&(*NewShellParameters)->Argc);
------------------------------------------------------------------------------
Monitor Your Dynamic Infrastructure at Any Scale With Datadog!
Get real-time metrics from all of your servers, apps and tools
in one place.
SourceForge users - Click here to start your Free Trial of Datadog now!
http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits