]> git.proxmox.com Git - mirror_edk2.git/blobdiff - ShellPkg/Application/Shell/ShellParametersProtocol.c
ShellPkg: fix redirection file parsing to allow spaces before filename.
[mirror_edk2.git] / ShellPkg / Application / Shell / ShellParametersProtocol.c
index 2d29ab1f2e11d12b67fbb3b4257420c3d5012ebe..c8ac00bc813b4f4082d30d6731794e0ad46f5832 100644 (file)
@@ -2,7 +2,7 @@
   Member functions of EFI_SHELL_PARAMETERS_PROTOCOL and functions for creation,\r
   manipulation, and initialization of EFI_SHELL_PARAMETERS_PROTOCOL.\r
 \r
-  Copyright (c) 2009 - 2011, Intel Corporation. All rights reserved.<BR>\r
+  Copyright (c) 2009 - 2012, Intel Corporation. All rights reserved.<BR>\r
   This program and the accompanying materials\r
   are licensed and made available under the terms and conditions of the BSD License\r
   which accompanies this distribution.  The full text of the license may be found at\r
@@ -523,6 +523,9 @@ FixFileName (
     }    \r
   } else {\r
     Copy = FileName;\r
+    while(Copy[0] == L' ') {\r
+      Copy++;\r
+    }\r
     if ((TempLocation = StrStr(Copy , L" ")) != NULL) {\r
       TempLocation[0] = CHAR_NULL;\r
     }    \r