forked from Imagelibrary/binutils-gdb
2012-03-02 Tom Tromey <tromey@redhat.com>
Pedro Alves <palves@redhat.com> PR breakpoints/13776: * breakpoint.c (breakpoint_init_inferior): Delete step-resume breakpoints. (delete_longjmp_breakpoint_at_next_stop): New. * breakpoint.h (delete_longjmp_breakpoint_at_next_stop): Declare. * target.c (generic_mourn_inferior): Call mark_breakpoints_out before deleting the inferior. Add comments. * thread.c (clear_thread_inferior_resources): Don't delete lonjmp breakpoints immediately, but only on next stop. Move that code next to where we mark other breakpoints for deletion.
This commit is contained in:
@@ -3341,6 +3341,10 @@ breakpoint_init_inferior (enum inf_context context)
|
||||
(gdb) tar rem :9999 # remote Windows gdbserver.
|
||||
*/
|
||||
|
||||
case bp_step_resume:
|
||||
|
||||
/* Also remove step-resume breakpoints. */
|
||||
|
||||
delete_breakpoint (b);
|
||||
break;
|
||||
|
||||
@@ -6624,6 +6628,19 @@ delete_longjmp_breakpoint (int thread)
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
delete_longjmp_breakpoint_at_next_stop (int thread)
|
||||
{
|
||||
struct breakpoint *b, *b_tmp;
|
||||
|
||||
ALL_BREAKPOINTS_SAFE (b, b_tmp)
|
||||
if (b->type == bp_longjmp || b->type == bp_exception)
|
||||
{
|
||||
if (b->thread == thread)
|
||||
b->disposition = disp_del_at_next_stop;
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
enable_overlay_breakpoints (void)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user