all repos — mgba @ 0dd69e827325a28b74f2a2d997bae7eb7ae48db3

mGBA Game Boy Advance Emulator

Fix incorrect condition in FIFO sampling
Jeffrey Pfau jeffrey@endrift.com
Thu, 03 Oct 2013 01:23:16 -0700
commit

0dd69e827325a28b74f2a2d997bae7eb7ae48db3

parent

da3802765454719c0fed68ee04589db81ad2bb73

1 files changed, 1 insertions(+), 1 deletions(-)

jump to
M src/gba/gba-audio.csrc/gba/gba-audio.c

@@ -143,7 +143,7 @@ } else {

GBALog(audio->p, GBA_LOG_ERROR, "Bad FIFO write to address 0x%03x", fifoId); return; } - if (CircleBufferSize(&channel->fifo) < 4 * sizeof(int32_t)) { + if (CircleBufferSize(&channel->fifo) <= 4 * sizeof(int32_t)) { struct GBADMA* dma = &audio->p->memory.dma[channel->dmaSource]; dma->nextCount = 4; GBAMemoryServiceDMA(&audio->p->memory, channel->dmaSource, dma);