diff --git a/Core/Config.cpp b/Core/Config.cpp index 8eb170f641..bd54508d01 100644 --- a/Core/Config.cpp +++ b/Core/Config.cpp @@ -1186,7 +1186,6 @@ void Config::ReadAllSettings(const IniFile &iniFile) { // Not found? Try the fallback (to upgrade settings that have been moved from old sections). if (!section && !meta.fallbackSectionName.empty()) { section = iniFile.GetSection(meta.fallbackSectionName); - configBlock = GetConfigBlockForSection(meta.fallbackSectionName); } // If section is still null, we'll handle that gracefully by resetting to defaults. _dbg_assert_(configBlock); @@ -1726,7 +1725,6 @@ bool Config::LoadGameConfig(const std::string &gameId) { // Not found? Try the fallback (to upgrade settings that have been moved from old sections). if (!section && !meta.fallbackSectionName.empty()) { section = iniFile.GetSection(meta.fallbackSectionName); - configBlock = GetConfigBlockForSection(meta.fallbackSectionName); } for (size_t j = 0; j < meta.settingsCount; j++) { meta.settings[j].ReadFromIniSection(configBlock, section, false); diff --git a/Core/Config.h b/Core/Config.h index 09acf0b059..f545575054 100644 --- a/Core/Config.h +++ b/Core/Config.h @@ -106,6 +106,8 @@ public: Config(); ~Config(); + u32 sentinel = 13371337; // For memory corruption debugging, just set a data breakpoint. + // Whether to save the config on close. bool bSaveSettings; bool bFirstRun; diff --git a/UI/DisplayLayoutScreen.cpp b/UI/DisplayLayoutScreen.cpp index 4e407a7138..d7996cb295 100644 --- a/UI/DisplayLayoutScreen.cpp +++ b/UI/DisplayLayoutScreen.cpp @@ -274,10 +274,11 @@ void DisplayLayoutScreen::CreateViews() { supportsInsets = true; #endif // Hide insets option if no insets, or OS too old. - if (supportsInsets && System_GetPropertyFloat(SYSPROP_DISPLAY_SAFE_INSET_LEFT) != 0.0f || + if (supportsInsets && + (System_GetPropertyFloat(SYSPROP_DISPLAY_SAFE_INSET_LEFT) != 0.0f || System_GetPropertyFloat(SYSPROP_DISPLAY_SAFE_INSET_TOP) != 0.0f || System_GetPropertyFloat(SYSPROP_DISPLAY_SAFE_INSET_RIGHT) != 0.0f || - System_GetPropertyFloat(SYSPROP_DISPLAY_SAFE_INSET_BOTTOM) != 0.0f) { + System_GetPropertyFloat(SYSPROP_DISPLAY_SAFE_INSET_BOTTOM) != 0.0f)) { rightColumn->Add(new CheckBox(&config.bIgnoreScreenInsets, gr->T("Ignore camera notch when centering"))); }