This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH v2 2/2] Only leave dprintf inserted if it is marked as persistent (PR breakpoints/17012)
- From: Joel Brobecker <brobecker at adacore dot com>
- To: Simon Marchi <simon dot marchi at ericsson dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Tue, 15 Jul 2014 09:07:40 -0700
- Subject: Re: [PATCH v2 2/2] Only leave dprintf inserted if it is marked as persistent (PR breakpoints/17012)
- Authentication-results: sourceware.org; auth=none
- References: <1404760664-17289-1-git-send-email-simon dot marchi at ericsson dot com> <1404760664-17289-2-git-send-email-simon dot marchi at ericsson dot com>
> 2014-07-07 Simon Marchi <simon.marchi@ericsson.com>
>
> PR breakpoints/17012
> * breakpoint.c (remove_breakpoints_pid): Only skip removing
> dprintf if it is marked as persistent.
Pedro is really the maintainer who is the most familiar with
breakpoint.c, I think, so it'd be better to wait for his feedback.
But, with my patch champion hat on, I would suggest merging both
patches into one, or else schedule the testsuite patch after the
actual fix. It's a bit of a detail in this case, but generally
speaking, we avoid having tests that fail until the fix is in.
> ---
> gdb/breakpoint.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c
> index 908a1ea..fb833d0 100644
> --- a/gdb/breakpoint.c
> +++ b/gdb/breakpoint.c
> @@ -3112,7 +3112,7 @@ remove_breakpoints_pid (int pid)
> if (bl->pspace != inf->pspace)
> continue;
>
> - if (bl->owner->type == bp_dprintf)
> + if (bl->owner->type == bp_dprintf && bl->target_info.persist == 1)
> continue;
>
> if (bl->inserted)
> --
> 2.0.0
--
Joel