fix: Fix macOS crashing on first install use (#6412)

With the new imgui OTR generation flow, macOS would crash when Ship
was run for the first time unless com.shipofharkinian.soh had already been created.
Move the call to CheckAndCreateModFolder() earlier in execution to prevent crashing.
This commit is contained in:
Ali 2026-03-26 11:12:51 -04:00 committed by GitHub
parent 69e03dcc52
commit 99c1f23d5b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -445,6 +445,11 @@ void OTRGlobals::RunExtract(int argc, char* argv[]) {
std::shared_ptr<BS::thread_pool> threadPool = std::make_shared<BS::thread_pool>(1);
std::optional<std::future<void>> extractionTask;
#if not defined(__SWITCH__) && not defined(__WIIU__)
CheckAndCreateModFolder();
#endif
while (!extractDone) {
if (SohGui::PopupsQueued() > 0 || extractionTask.has_value()) {
goto render;
@ -760,10 +765,6 @@ void OTRGlobals::RunExtract(int argc, char* argv[]) {
#elif defined(__WIIU__)
Ship::WiiU::Init(appShortName);
#endif
#if not defined(__SWITCH__) && not defined(__WIIU__)
CheckAndCreateModFolder();
#endif
}
void OTRGlobals::Initialize() {