Fix settings issue where settings.json would get reset on runner startup (#4524)

* Added flag to avoid saving before modules is initialized

* Added comment
This commit is contained in:
Arjun Balgovind
2020-06-26 14:46:47 -07:00
committed by GitHub
parent d17fc86fa4
commit 55272e5ea2
3 changed files with 11 additions and 6 deletions

View File

@@ -376,7 +376,9 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine
modules();
auto general_settings = load_general_settings();
apply_general_settings(general_settings);
// Apply the general settings but don't save it as the modules() variable has not been loaded yet
apply_general_settings(general_settings, false);
int rvalue = 0;
const bool elevated = is_process_elevated();
if ((elevated ||