GB Audio: Fix deserializing while audio was disabled (fixes #1305)
Vicki Pfau vi@endrift.com
Mon, 24 Aug 2020 01:19:45 -0700
2 files changed,
2 insertions(+),
1 deletions(-)
M
CHANGES
→
CHANGES
@@ -16,6 +16,7 @@ - GB: Partially fix timing for skipped BIOS
- GB Audio: Fix initial sweep state - GB Audio: Fix serializing sweep time - GB Audio: Fix deserializing audio channels 2 and 3 + - GB Audio: Fix deserializing while audio was disabled (fixes mgba.io/i/1305) - GB MBC: Fix MBC1 mode changing behavior - GB Video: Fix state after skipping BIOS (fixes mgba.io/i/1715 and mgba.io/i/1716) - GBA: Fix timing advancing too quickly in rare cases
M
src/gb/io.c
→
src/gb/io.c
@@ -700,7 +700,7 @@ memcpy(gb->memory.io, state->io, GB_SIZE_IO);
gb->memory.ie = state->ie; gb->audio.enable = GBAudioEnableGetEnable(*gb->audio.nr52); - if (GBAudioEnableGetEnable(gb->audio.enable)) { + if (gb->audio.enable) { GBIOWrite(gb, REG_NR10, gb->memory.io[REG_NR10]); GBIOWrite(gb, REG_NR11, gb->memory.io[REG_NR11]); GBIOWrite(gb, REG_NR12, gb->memory.io[REG_NR12]);