aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/ChangeLog6
-rw-r--r--gdb/inf-ttrace.c6
2 files changed, 11 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 3c83d5d..f40d597 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,11 @@
2012-08-16 Joel Brobecker <brobecker@adacore.com>
+ * inf-ttrace.c (inf_ttrace_follow_fork): When following the
+ parent, only call detach_breakpoints if tts.tts_event ==
+ TTEVT_VFORK.
+
+2012-08-16 Joel Brobecker <brobecker@adacore.com>
+
* dwarf2-frame.c (dwarf2_frame_cache): Use
get_frame_address_in_block instead of get_frame_pc as
the bound for executing the frame's FDE.
diff --git a/gdb/inf-ttrace.c b/gdb/inf-ttrace.c
index 2c620d5..ddcbd42 100644
--- a/gdb/inf-ttrace.c
+++ b/gdb/inf-ttrace.c
@@ -467,7 +467,11 @@ inf_ttrace_follow_fork (struct target_ops *ops, int follow_child)
else
{
inferior_ptid = ptid_build (pid, lwpid, 0);
- detach_breakpoints (fpid);
+ /* Detach any remaining breakpoints in the child. In the case
+ of fork events, we do not need to do this, because breakpoints
+ should have already been removed earlier. */
+ if (tts.tts_event == TTEVT_VFORK)
+ detach_breakpoints (fpid);
target_terminal_ours ();
fprintf_unfiltered (gdb_stdlog,