Lets fix Stuart Little 2 properly (maybe?)

This game cart may have a flashcontroller but no flashram onboard, the game automatically goes down the Flash Type path and hits a stackoverflow at cpuSaveGameFunc after cpuSramEnabled returns as false

I'm not sure of the specifics, but with this change it seems to avoid this condition.

I have tested a number of titles that create Sram, 512 and 1024Mbit flash and they all still seem to just fine.
This commit is contained in:
Squall Leonhart 2023-02-28 06:00:21 +11:00 committed by Rafael Kitover
parent a9284b3d66
commit 9a8a077443
1 changed files with 3 additions and 0 deletions

View File

@ -103,6 +103,9 @@ void flashSaveDecide(uint32_t address, uint8_t byte)
cpuSramEnabled ? "SRAM" : "FLASH", address, byte);
}
if (coreOptions.saveType == GBA_SAVE_NONE)
return;
(*cpuSaveGameFunc)(address, byte);
}