GBA Memory: Fix copy-on-write memory leak

This commit is contained in:
Vicki Pfau 2018-01-08 23:49:48 -08:00
parent 12931fbe25
commit 36a0f43dc2
2 changed files with 2 additions and 0 deletions

View File

@ -37,6 +37,7 @@ Bugfixes:
- GBA Audio: Increase PSG volume (fixes mgba.io/i/932) - GBA Audio: Increase PSG volume (fixes mgba.io/i/932)
- 3DS: Fix opening files in directory names with trailing slashes - 3DS: Fix opening files in directory names with trailing slashes
- GB MBC: Fix MBC2 saves (fixes mgba.io/i/954) - GB MBC: Fix MBC2 saves (fixes mgba.io/i/954)
- GBA Memory: Fix copy-on-write memory leak
Misc: Misc:
- GBA Timer: Use global cycles for timers - GBA Timer: Use global cycles for timers
- GBA: Extend oddly-sized ROMs to full address space (fixes mgba.io/i/722) - GBA: Extend oddly-sized ROMs to full address space (fixes mgba.io/i/722)

View File

@ -1635,6 +1635,7 @@ void _pristineCow(struct GBA* gba) {
} }
gba->memory.rom = newRom; gba->memory.rom = newRom;
gba->memory.hw.gpioBase = &((uint16_t*) gba->memory.rom)[GPIO_REG_DATA >> 1]; gba->memory.hw.gpioBase = &((uint16_t*) gba->memory.rom)[GPIO_REG_DATA >> 1];
gba->isPristine = false;
} }
void GBAPrintFlush(struct GBA* gba) { void GBAPrintFlush(struct GBA* gba) {