GB Memory: Fix null deref when rumbling
Jeffrey Pfau jeffrey@endrift.com
Mon, 30 May 2016 15:08:42 -0700
1 files changed,
1 insertions(+),
1 deletions(-)
jump to
M
src/gb/memory.c
→
src/gb/memory.c
@@ -721,7 +721,7 @@ _switchBank(memory, bank);
break; case 0x4: case 0x5: - if (memory->mbcType == GB_MBC5_RUMBLE) { + if (memory->mbcType == GB_MBC5_RUMBLE && memory->rumble) { memory->rumble->setRumble(memory->rumble, (value >> 3) & 1); value &= ~8; }