Skip to content

Commit

Permalink
Encode backslashes in MC filenames.
Browse files Browse the repository at this point in the history
Blackhawk Down uses this in one of its filenames, causing issues on Windows.
  • Loading branch information
jpd002 committed Nov 21, 2024
1 parent a256a16 commit d5af62f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Source/iop/Iop_McServ.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,8 @@ std::string CMcServ::EncodeMcName(const std::string& inputName)
{
auto inputChar = inputName[i];
if(inputChar == 0) break;
//':' is not allowed on Windows
if(inputChar == ':')
//Encode problematic characters (for Windows)
if((inputChar == ':') || (inputChar == '\\'))
{
result += string_format("%%%02X", inputChar);
}
Expand Down

0 comments on commit d5af62f

Please sign in to comment.