(Windows) Fixed an issue where a forward slash instead of a backslash was added to the ROM directory.

This commit is contained in:
Leon Styhre 2021-03-10 19:49:06 +01:00
parent f8e23a016e
commit 101c7f888f

View file

@ -171,8 +171,13 @@ const std::string FileData::getROMDirectory()
// Expand home path if ~ is used.
romDirPath = Utils::FileSystem::expandHomePath(romDirPath);
#if defined(_WIN64)
if (romDirPath.back() != '\\')
romDirPath = romDirPath + "\\";
#else
if (romDirPath.back() != '/')
romDirPath = romDirPath + "/";
#endif
}
// If %ESPATH% is used for the ROM path configuration, then expand it to the executable