mirror of
https://github.com/cemu-project/Cemu.git
synced 2026-07-11 01:25:15 +02:00
unix: simplify the case-insensitivity algorithm
This commit is contained in:
@@ -9,13 +9,8 @@ fs::path findPathCI(const fs::path& path)
|
||||
fs::path parentPath = path.parent_path();
|
||||
if (parentPath.empty())
|
||||
parentPath = ".";
|
||||
|
||||
if (!fs::exists(parentPath))
|
||||
{
|
||||
auto CIParent = findPathCI(parentPath);
|
||||
if (fs::exists(CIParent))
|
||||
return findPathCI(CIParent / fName);
|
||||
}
|
||||
else if (!fs::exists(parentPath))
|
||||
parentPath = findPathCI(parentPath);
|
||||
|
||||
std::error_code listErr;
|
||||
for (auto&& dirEntry : fs::directory_iterator(parentPath, listErr))
|
||||
|
||||
Reference in New Issue
Block a user