From beced16dd084ffecb51ec30c25e761a1648b9076 Mon Sep 17 00:00:00 2001 From: pineappleEA Date: Tue, 3 Aug 2021 07:02:43 +0200 Subject: [PATCH] early-access version 1961 --- README.md | 2 +- src/core/network/network.cpp | 2 +- src/yuzu/configuration/config.cpp | 11 ++++++----- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 8f0d6c53c..6939dd124 100755 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ yuzu emulator early access ============= -This is the source code for early-access 1959. +This is the source code for early-access 1961. ## Legal Notice diff --git a/src/core/network/network.cpp b/src/core/network/network.cpp index 526bfa110..375bc79ec 100755 --- a/src/core/network/network.cpp +++ b/src/core/network/network.cpp @@ -570,7 +570,7 @@ std::pair Socket::SendTo(u32 flags, const std::vector& message, ASSERT(flags == 0); const sockaddr* to = nullptr; - const int tolen = addr ? 0 : sizeof(sockaddr); + const int tolen = addr ? sizeof(sockaddr) : 0; sockaddr host_addr_in; if (addr) { diff --git a/src/yuzu/configuration/config.cpp b/src/yuzu/configuration/config.cpp index e1fcc8077..ba34f789f 100755 --- a/src/yuzu/configuration/config.cpp +++ b/src/yuzu/configuration/config.cpp @@ -888,10 +888,6 @@ void Config::ReadShortcutValues() { void Config::ReadSystemValues() { qt_config->beginGroup(QStringLiteral("System")); - ReadBasicSetting(Settings::values.current_user); - Settings::values.current_user = std::clamp(Settings::values.current_user.GetValue(), 0, - Service::Account::MAX_USERS - 1); - ReadGlobalSetting(Settings::values.language_index); ReadGlobalSetting(Settings::values.region_index); @@ -912,6 +908,10 @@ void Config::ReadSystemValues() { } if (global) { + ReadBasicSetting(Settings::values.current_user); + Settings::values.current_user = std::clamp(Settings::values.current_user.GetValue(), 0, + Service::Account::MAX_USERS - 1); + const auto custom_rtc_enabled = ReadSetting(QStringLiteral("custom_rtc_enabled"), false).toBool(); if (custom_rtc_enabled) { @@ -1430,7 +1430,6 @@ void Config::SaveShortcutValues() { void Config::SaveSystemValues() { qt_config->beginGroup(QStringLiteral("System")); - WriteBasicSetting(Settings::values.current_user); WriteGlobalSetting(Settings::values.language_index); WriteGlobalSetting(Settings::values.region_index); WriteGlobalSetting(Settings::values.time_zone_index); @@ -1442,6 +1441,8 @@ void Config::SaveSystemValues() { 0, Settings::values.rng_seed.UsingGlobal()); if (global) { + WriteBasicSetting(Settings::values.current_user); + WriteSetting(QStringLiteral("custom_rtc_enabled"), Settings::values.custom_rtc.has_value(), false); WriteSetting(QStringLiteral("custom_rtc"),