Fix a crash when using DSi mode in debug builds on macOS (#1976)

Store the BIOS images in `NDSArgs`/`DSiArgs` through pointers, not directly

- This will make it easier to keep such objects on the stack
This commit is contained in:
Jesse Talavera
2024-03-13 09:55:20 -04:00
committed by GitHub
parent ea1755bed0
commit 31a7f53282
6 changed files with 45 additions and 39 deletions

View File

@ -131,8 +131,8 @@ std::unique_ptr<NDS> EmuThread::CreateConsole(
NDSArgs ndsargs {
std::move(ndscart),
std::move(gbacart),
*arm9bios,
*arm7bios,
std::move(arm9bios),
std::move(arm7bios),
std::move(*firmware),
#ifdef JIT_ENABLED
Config::JIT_Enable ? std::make_optional(jitargs) : std::nullopt,
@ -165,8 +165,8 @@ std::unique_ptr<NDS> EmuThread::CreateConsole(
auto sdcard = ROMManager::LoadDSiSDCard();
DSiArgs args {
std::move(ndsargs),
*arm9ibios,
*arm7ibios,
std::move(arm9ibios),
std::move(arm7ibios),
std::move(*nand),
std::move(sdcard),
Config::DSiFullBIOSBoot,