From b4208be4f4b27bc6558475843f9f4f42ebf6493e Mon Sep 17 00:00:00 2001 From: Lior Halphon Date: Sat, 9 Jul 2016 14:37:11 +0300 Subject: [PATCH] Multiple watchpoints were broken --- Core/debugger.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/debugger.c b/Core/debugger.c index 38cf57c..3b09c35 100644 --- a/Core/debugger.c +++ b/Core/debugger.c @@ -965,7 +965,7 @@ void GB_debugger_ret_hook(GB_gameboy_t *gb) void GB_debugger_test_write_watchpoint(GB_gameboy_t *gb, uint16_t addr, uint8_t value) { - uint16_t index = find_breakpoint(gb, addr); + uint16_t index = find_watchpoint(gb, addr); if (index < gb->n_watchpoints && gb->watchpoints[index].addr == addr) { if (!(gb->watchpoints[index].flags & GB_WATCHPOINT_W)) { return;