aboutsummaryrefslogtreecommitdiffstats
path: root/source/tools/acpiexec/aemain.c
diff options
context:
space:
mode:
Diffstat (limited to 'source/tools/acpiexec/aemain.c')
-rw-r--r--source/tools/acpiexec/aemain.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/source/tools/acpiexec/aemain.c b/source/tools/acpiexec/aemain.c
index a5d519c1e178..d0e980b5a1fb 100644
--- a/source/tools/acpiexec/aemain.c
+++ b/source/tools/acpiexec/aemain.c
@@ -239,16 +239,20 @@ FlSplitInputPathname (
return (AE_NO_MEMORY);
}
- Substring = strrchr (DirectoryPath, '\\');
+ /* Convert backslashes to slashes in the entire path */
+
+ UtConvertBackslashes (DirectoryPath);
+
+ /* Backup to last slash or colon */
+
+ Substring = strrchr (DirectoryPath, '/');
if (!Substring)
{
- Substring = strrchr (DirectoryPath, '/');
- if (!Substring)
- {
- Substring = strrchr (DirectoryPath, ':');
- }
+ Substring = strrchr (DirectoryPath, ':');
}
+ /* Extract the simple filename */
+
if (!Substring)
{
DirectoryPath[0] = 0;
@@ -267,7 +271,6 @@ FlSplitInputPathname (
*OutDirectoryPath = DirectoryPath;
*OutFilename = Filename;
-
return (AE_OK);
}