From eab402dfcc7dc809c501ab4ebfe9feba17355b4d Mon Sep 17 00:00:00 2001 From: Pedro Alves Date: Wed, 18 Jul 2012 18:04:39 +0000 Subject: [PATCH] 2012-07-18 Pedro Alves * infrun.c (handle_inferior_event) : Pull the single step breakpoints out of the target. --- gdb/ChangeLog | 5 +++++ gdb/infrun.c | 9 +++++++++ 2 files changed, 14 insertions(+) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 31f15c225d..0f15a845d5 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2012-07-18 Pedro Alves + + * infrun.c (handle_inferior_event) : + Pull the single step breakpoints out of the target. + 2012-07-18 Sergio Durigan Junior * probe.c (probe_safe_evaluate_at_pc): Rename variable `n_probes'. diff --git a/gdb/infrun.c b/gdb/infrun.c index bd209f76d2..49a442c871 100644 --- a/gdb/infrun.c +++ b/gdb/infrun.c @@ -3669,6 +3669,15 @@ handle_inferior_event (struct execution_control_state *ecs) if (debug_infrun) fprintf_unfiltered (gdb_stdlog, "infrun: TARGET_WAITKIND_NO_HISTORY\n"); /* Reverse execution: target ran out of history info. */ + + /* Pull the single step breakpoints out of the target. */ + if (singlestep_breakpoints_inserted_p) + { + if (!ptid_equal (ecs->ptid, inferior_ptid)) + context_switch (ecs->ptid); + remove_single_step_breakpoints (); + singlestep_breakpoints_inserted_p = 0; + } stop_pc = regcache_read_pc (get_thread_regcache (ecs->ptid)); print_no_history_reason (); stop_stepping (ecs); -- 2.34.1