GB: Cancel IRQs if interrupt is unasserted before dispatch (fixes #1000, #1003)

This commit is contained in:
Vicki Pfau 2018-03-01 10:15:22 -08:00
parent 369bcc9511
commit fd0af73f32
1 changed files with 1 additions and 0 deletions

View File

@ -526,6 +526,7 @@ void GBDetectModel(struct GB* gb) {
void GBUpdateIRQs(struct GB* gb) {
int irqs = gb->memory.ie & gb->memory.io[REG_IF];
if (!irqs) {
gb->cpu->irqPending = false;
return;
}
gb->cpu->halted = false;