diff --git a/library/Core.cpp b/library/Core.cpp index c724a0fcc..222680f62 100644 --- a/library/Core.cpp +++ b/library/Core.cpp @@ -1529,6 +1529,7 @@ Core::Core() : HotkeyMutex{}, HotkeyCond{}, alias_mutex{}, + started{false}, misc_data_mutex{}, CoreSuspendMutex{}, CoreWakeup{}, @@ -1538,7 +1539,7 @@ Core::Core() : // init the console. This must be always the first step! plug_mgr = 0; errorstate = false; - started = false; + vinfo = 0; memset(&(s_mods), 0, sizeof(s_mods)); // set up hotkey capture diff --git a/library/include/Core.h b/library/include/Core.h index 0fec2774d..7c3bc5578 100644 --- a/library/include/Core.h +++ b/library/include/Core.h @@ -283,7 +283,7 @@ namespace DFHack df::viewscreen *top_viewscreen; bool last_pause_state; // Very important! - bool started; + std::atomic started; // Additional state change scripts std::vector state_change_scripts;