Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SettingsHandler: Always decode the whole settings.txt file #8680

Merged
merged 1 commit into from
Mar 23, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
SettingsHandler: Always decode the whole settings.txt file
  • Loading branch information
Leseratte10 committed Mar 20, 2020
commit cba4acc54bbf117026a9d79e6f29f1304ae9ae46
4 changes: 1 addition & 3 deletions Source/Core/Common/SettingsHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,8 @@ std::string SettingsHandler::GetValue(std::string_view key) const
void SettingsHandler::Decrypt()
{
const u8* str = m_buffer.data();
while (*str != 0)
while (m_position < m_buffer.size())
{
if (m_position >= m_buffer.size())
return;
decoded.push_back((u8)(m_buffer[m_position] ^ m_key));
m_position++;
str++;
Expand Down