summaryrefslogtreecommitdiff
path: root/ShellPkg/Library/BasePathLib/BasePathLib.c
diff options
context:
space:
mode:
Diffstat (limited to 'ShellPkg/Library/BasePathLib/BasePathLib.c')
-rw-r--r--ShellPkg/Library/BasePathLib/BasePathLib.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/ShellPkg/Library/BasePathLib/BasePathLib.c b/ShellPkg/Library/BasePathLib/BasePathLib.c
index cc46c0fc33..301bd3b279 100644
--- a/ShellPkg/Library/BasePathLib/BasePathLib.c
+++ b/ShellPkg/Library/BasePathLib/BasePathLib.c
@@ -116,7 +116,15 @@ PathCleanUpDirectories(
*(TempString + 1) = CHAR_NULL;
}
-
+ while ((TempString = StrStr(Path, L"\\\\")) != NULL) {
+ *TempString = CHAR_NULL;
+ TempString += 1;
+ TempSize = StrSize(TempString);
+ CopyMem(Path+StrLen(Path), TempString, TempSize);
+ }
+ if ((TempString = StrStr(Path, L"\\\\")) != NULL && *(TempString + 1) == CHAR_NULL) {
+ *(TempString) = CHAR_NULL;
+ }
return (Path);
}