diff options
| author | JosJuice <josjuice@gmail.com> | 2017-06-03 20:40:05 +0200 |
|---|---|---|
| committer | JosJuice <josjuice@gmail.com> | 2017-06-03 20:46:57 +0200 |
| commit | f71fcd38bd445d8cb3777b42cfa3ca61d10f8cb1 (patch) | |
| tree | 26262d2a2358dd8f5e19c8438be10afecbb54212 | |
| parent | 4493b1324bf305b4530a6748bd69e2f9b3275619 (diff) | |
TitleDatabase: Check game ID length before reading characters
| -rw-r--r-- | Source/Core/Core/TitleDatabase.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/Core/Core/TitleDatabase.cpp b/Source/Core/Core/TitleDatabase.cpp index c138d3698b..9225d6705d 100644 --- a/Source/Core/Core/TitleDatabase.cpp +++ b/Source/Core/Core/TitleDatabase.cpp @@ -67,7 +67,7 @@ static bool LoadMap(const std::string& file_path, Map& map, if (equals_index != std::string::npos) { const std::string game_id = StripSpaces(line.substr(0, equals_index)); - if (predicate(game_id)) + if (game_id.length() >= 4 && predicate(game_id)) map[game_id] = StripSpaces(line.substr(equals_index + 1)); } } |
