Skip to content

Commit

Permalink
Fixed regression in 220ac5f causing em dashes to be considered invali…
Browse files Browse the repository at this point in the history
…d filename chars

Fixes #2422. Since em dashes were considered invalid, and MP scenario names almost all have
em dashes, savegames were created without them, and thus the game couldn't match any when
generating entries for the Back to Turn... menu.
  • Loading branch information
Vultraz committed Feb 7, 2018
1 parent 7bf4798 commit 057a530
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/savegame.cpp
Expand Up @@ -418,7 +418,7 @@ bool savegame::check_filename(const std::string& filename)

bool savegame::is_illegal_file_char(char c)
{
return c == '/' || c == '\\' || c == ':' || c < 0x20
return c == '/' || c == '\\' || c == ':' || (c >= 0x00 && c < 0x20)
#ifdef _WIN32
|| c == '?' || c == '|' || c == '<' || c == '>' || c == '*' || c == '"'
#endif
Expand Down

0 comments on commit 057a530

Please sign in to comment.