From a82629efd51ba883a76b81c7ce2582111ab1a316 Mon Sep 17 00:00:00 2001 From: Ben Vanik Date: Sun, 4 Jan 2015 21:08:47 -0800 Subject: [PATCH] Fix dots in path names. --- src/xenia/kernel/fs/filesystem.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/xenia/kernel/fs/filesystem.cc b/src/xenia/kernel/fs/filesystem.cc index 760c9329d..87be60c1e 100644 --- a/src/xenia/kernel/fs/filesystem.cc +++ b/src/xenia/kernel/fs/filesystem.cc @@ -32,7 +32,11 @@ FileSystem::~FileSystem() { } fs::FileSystemType FileSystem::InferType(const std::wstring& local_path) { + auto last_slash = local_path.find_last_of(poly::path_separator); auto last_dot = local_path.find_last_of('.'); + if (last_dot < last_slash) { + last_dot = std::wstring::npos; + } if (last_dot == std::wstring::npos) { // Likely an STFS container. return FileSystemType::STFS_TITLE;