GB: Fix crash when masking savedata

This commit is contained in:
Jeffrey Pfau 2016-12-19 18:47:20 -08:00
parent 85367c3713
commit bf2aa98338
2 changed files with 2 additions and 0 deletions

View File

@ -35,6 +35,7 @@ Bugfixes:
- ARM7: PSR mode bits should not get sign extended
- GBA: Only unhalt CPU if appropriate bit is set in IE
- GBA Video: Fix out of bounds sprite transforms
- GB: Fix crash when masking savedata
Misc:
- SDL: Remove scancode key input
- GBA Video: Clean up unused timers

View File

@ -225,6 +225,7 @@ void GBSavedataMask(struct GB* gb, struct VFile* vf, bool writeback) {
gb->sramVf = vf;
gb->sramMaskWriteback = writeback;
gb->memory.sram = vf->map(vf, gb->sramSize, MAP_READ);
GBMBCSwitchSramBank(gb, gb->memory.sramCurrentBank);
}
void GBSavedataUnmask(struct GB* gb) {