From 54f45f2fd33d593f8550e529fb10f3afc7b1f932 Mon Sep 17 00:00:00 2001 From: Lior Halphon Date: Fri, 28 Jul 2023 00:47:15 +0300 Subject: [PATCH] Fix a bug where jump-to breakpoint disassembled the wrong address under certain scenarios --- Core/debugger.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/debugger.c b/Core/debugger.c index 49bcea5..98c9b24 100644 --- a/Core/debugger.c +++ b/Core/debugger.c @@ -2512,8 +2512,8 @@ next_command: else { gb->non_trivial_jump_breakpoint_occured = true; GB_log(gb, "Jumping to breakpoint: PC = %s\n", value_to_string(gb, gb->pc, true)); - GB_cpu_disassemble(gb, gb->pc, 5); GB_load_state_from_buffer(gb, gb->nontrivial_jump_state, -1); + GB_cpu_disassemble(gb, gb->pc, 5); GB_debugger_break(gb); } }