summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorConnor McLaughlin <stenzek@gmail.com>2019-08-10 21:27:24 +1000
committerGitHub <noreply@github.com>2019-08-10 21:27:24 +1000
commitdd8bc7b3e60642129c955f4f03f498d90ecb2c14 (patch)
treee4dbe58417c79d8cb1729e1d304519be5b40a576 /Source/Core
parent7e49a34df2a054c1dfb0dd26cba67bb497e4a99b (diff)
parent9cc719db02a1f52aa8df0270649c4a6dac478f41 (diff)
Merge pull request #8307 from JosJuice/fix-titledatabase
Fix TitleDatabase
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/Core/TitleDatabase.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/Source/Core/Core/TitleDatabase.cpp b/Source/Core/Core/TitleDatabase.cpp
index 84f8f0b9f2..86f9a9feae 100644
--- a/Source/Core/Core/TitleDatabase.cpp
+++ b/Source/Core/Core/TitleDatabase.cpp
@@ -41,9 +41,10 @@ static Map LoadMap(const std::string& file_path)
const size_t equals_index = line.find('=');
if (equals_index != std::string::npos)
{
- const std::string_view game_id = StripSpaces(line.substr(0, equals_index));
+ const std::string_view line_view(line);
+ const std::string_view game_id = StripSpaces(line_view.substr(0, equals_index));
if (game_id.length() >= 4)
- map.emplace(game_id, StripSpaces(line.substr(equals_index + 1)));
+ map.emplace(game_id, StripSpaces(line_view.substr(equals_index + 1)));
}
}
return map;