diff --git a/source/dllmain.cpp b/source/dllmain.cpp index 0cabf4f..ee860fb 100644 --- a/source/dllmain.cpp +++ b/source/dllmain.cpp @@ -717,7 +717,7 @@ std::filesystem::path GetFileName(auto lpFilename) auto filePath = std::filesystem::path(lpFilename); auto absolutePath = std::filesystem::absolute(filePath, ec); - auto relativePath = std::filesystem::relative(absolutePath, gamePath, ec); + auto relativePath = absolutePath.lexically_relative(gamePath); auto commonPath = gamePath; if (starts_with(relativePath, ".."))