diff --git a/src/common/file_system.cpp b/src/common/file_system.cpp index 53445e00b..d6a6dc816 100644 --- a/src/common/file_system.cpp +++ b/src/common/file_system.cpp @@ -112,7 +112,7 @@ void CanonicalizePath(char* Destination, u32 cbDestination, const char* Path, bo // fix ospath if (OSPath && (currentCh == '\\' || currentCh == '/')) - currentCh = FS_OSPATH_SEPERATOR_CHARACTER; + currentCh = FS_OSPATH_SEPARATOR_CHARACTER; // copy character if (destinationLength < cbDestination) @@ -547,7 +547,7 @@ void BuildOSPath(char* Destination, u32 cbDestination, const char* Path) for (i = 0; i < pathLength; i++) { if (Destination[i] == '/') - Destination[i] = FS_OSPATH_SEPERATOR_CHARACTER; + Destination[i] = FS_OSPATH_SEPARATOR_CHARACTER; } } else @@ -556,7 +556,7 @@ void BuildOSPath(char* Destination, u32 cbDestination, const char* Path) pathLength = std::max(pathLength, cbDestination - 1); for (i = 0; i < pathLength; i++) { - Destination[i] = (Path[i] == '/') ? FS_OSPATH_SEPERATOR_CHARACTER : Path[i]; + Destination[i] = (Path[i] == '/') ? FS_OSPATH_SEPARATOR_CHARACTER : Path[i]; } Destination[pathLength] = '\0'; @@ -576,7 +576,7 @@ void BuildOSPath(String& Destination, const char* Path) for (i = 0; i < pathLength; i++) { if (Destination[i] == '/') - Destination[i] = FS_OSPATH_SEPERATOR_CHARACTER; + Destination[i] = FS_OSPATH_SEPARATOR_CHARACTER; } } else @@ -586,7 +586,7 @@ void BuildOSPath(String& Destination, const char* Path) Destination.Resize(pathLength); for (i = 0; i < pathLength; i++) { - Destination[i] = (Path[i] == '/') ? FS_OSPATH_SEPERATOR_CHARACTER : Path[i]; + Destination[i] = (Path[i] == '/') ? FS_OSPATH_SEPARATOR_CHARACTER : Path[i]; } } } diff --git a/src/common/file_system.h b/src/common/file_system.h index e7a804bd5..52cbad856 100644 --- a/src/common/file_system.h +++ b/src/common/file_system.h @@ -10,10 +10,10 @@ class ByteStream; #ifdef WIN32 -#define FS_OSPATH_SEPERATOR_CHARACTER '\\' +#define FS_OSPATH_SEPARATOR_CHARACTER '\\' #define FS_OSPATH_SEPARATOR_STR "\\" #else -#define FS_OSPATH_SEPERATOR_CHARACTER '/' +#define FS_OSPATH_SEPARATOR_CHARACTER '/' #define FS_OSPATH_SEPARATOR_STR "/" #endif diff --git a/src/duckstation-qt/qthostinterface.cpp b/src/duckstation-qt/qthostinterface.cpp index e123afe67..258b66f74 100644 --- a/src/duckstation-qt/qthostinterface.cpp +++ b/src/duckstation-qt/qthostinterface.cpp @@ -767,7 +767,7 @@ void QtHostInterface::saveInputProfile(const QString& profile_name) QString QtHostInterface::getUserDirectoryRelativePath(const QString& arg) const { QString result = QString::fromStdString(m_user_directory); - result += FS_OSPATH_SEPERATOR_CHARACTER; + result += FS_OSPATH_SEPARATOR_CHARACTER; result += arg; return result; } @@ -775,7 +775,7 @@ QString QtHostInterface::getUserDirectoryRelativePath(const QString& arg) const QString QtHostInterface::getProgramDirectoryRelativePath(const QString& arg) const { QString result = QString::fromStdString(m_program_directory); - result += FS_OSPATH_SEPERATOR_CHARACTER; + result += FS_OSPATH_SEPARATOR_CHARACTER; result += arg; return result; } diff --git a/src/frontend-common/game_list.cpp b/src/frontend-common/game_list.cpp index 838638db6..5c604b6c2 100644 --- a/src/frontend-common/game_list.cpp +++ b/src/frontend-common/game_list.cpp @@ -1157,9 +1157,9 @@ std::string GameList::GetCoverImagePathForEntry(const GameListEntry* entry) cons { cover_path.Clear(); cover_path.AppendString(g_host_interface->GetUserDirectory().c_str()); - cover_path.AppendCharacter(FS_OSPATH_SEPERATOR_CHARACTER); + cover_path.AppendCharacter(FS_OSPATH_SEPARATOR_CHARACTER); cover_path.AppendString("covers"); - cover_path.AppendCharacter(FS_OSPATH_SEPERATOR_CHARACTER); + cover_path.AppendCharacter(FS_OSPATH_SEPARATOR_CHARACTER); cover_path.AppendString(file_title.data(), static_cast<u32>(file_title.size())); cover_path.AppendCharacter('.'); cover_path.AppendString(extension); diff --git a/src/updater/updater.cpp b/src/updater/updater.cpp index 3d5a1ab84..53f1979de 100644 --- a/src/updater/updater.cpp +++ b/src/updater/updater.cpp @@ -98,15 +98,15 @@ bool Updater::ParseZip() for (size_t i = 0; i < len; i++) { if (zip_filename_buffer[i] == '/' || zip_filename_buffer[i] == '\\') - zip_filename_buffer[i] = FS_OSPATH_SEPERATOR_CHARACTER; + zip_filename_buffer[i] = FS_OSPATH_SEPARATOR_CHARACTER; } // should never have a leading slash. just in case. - while (zip_filename_buffer[0] == FS_OSPATH_SEPERATOR_CHARACTER) + while (zip_filename_buffer[0] == FS_OSPATH_SEPARATOR_CHARACTER) std::memmove(&zip_filename_buffer[1], &zip_filename_buffer[0], --len); // skip directories (we sort them out later) - if (len > 0 && zip_filename_buffer[len - 1] != FS_OSPATH_SEPERATOR_CHARACTER) + if (len > 0 && zip_filename_buffer[len - 1] != FS_OSPATH_SEPARATOR_CHARACTER) { // skip updater itself, since it was already pre-extracted. if (StringUtil::Strcasecmp(zip_filename_buffer, "updater.exe") != 0) @@ -138,10 +138,10 @@ bool Updater::ParseZip() const size_t len = ftu.destination_filename.length(); for (size_t i = 0; i < len; i++) { - if (ftu.destination_filename[i] == FS_OSPATH_SEPERATOR_CHARACTER) + if (ftu.destination_filename[i] == FS_OSPATH_SEPARATOR_CHARACTER) { std::string dir(ftu.destination_filename.begin(), ftu.destination_filename.begin() + i); - while (!dir.empty() && dir[dir.length() - 1] == FS_OSPATH_SEPERATOR_CHARACTER) + while (!dir.empty() && dir[dir.length() - 1] == FS_OSPATH_SEPARATOR_CHARACTER) dir.erase(dir.length() - 1); if (std::find(m_update_directories.begin(), m_update_directories.end(), dir) == m_update_directories.end())