This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH] Fix for follow-fork: followed child doesn't stop
- From: Luis Machado <lgustavo at codesourcery dot com>
- To: "Breazeal, Don" <donb at codesourcery dot com>, <gdb-patches at sourceware dot org>
- Date: Fri, 6 Jun 2014 13:27:29 +0100
- Subject: Re: [PATCH] Fix for follow-fork: followed child doesn't stop
- Authentication-results: sourceware.org; auth=none
- References: <1401920383-10219-1-git-send-email-donb at codesourcery dot com> <53906D28 dot 5000404 at codesourcery dot com> <5390E4D1 dot 2050108 at codesourcery dot com>
- Reply-to: <lgustavo at codesourcery dot com>
Hi Don,
On 06/05/2014 10:44 PM, Breazeal, Don wrote:
Hi Luis,
Thanks for the review.
+ if (tp->control.step_resume_breakpoint != NULL)
+ tp->control.step_resume_breakpoint->loc->inserted = 0;
Maybe add a little more context as to why this conditional is doing what
it is doing? I imagine someone scratching their head to figure this out.
Your description above makes good sense.
I added a comment above the conditional. Let me know if it isn't what
you had in mind.
That looks good to me. Thanks.
--snip--
- if [runto_main] then { explicit_fork_parent_follow }
+ # The first two tests should be sufficient to test the defaults.
+ # There is no need to test using the defaults in other permutations
+ # (e.g. "default" "on", "parent" "default", etc.).
+ set cases [list [list "default" "default" "next 2"] \
+ [list "default" "default" "continue"] \
+ [list "parent" "on" "next 2"] \
+ [list "parent" "on" "continue"] \
+ [list "child" "on" "next 2"] \
+ [list "child" "on" "continue"] \
+ [list "parent" "off" "next 2"] \
+ [list "parent" "off" "continue"] \
+ [list "child" "off" "next 2"] \
+ [list "child" "off" "continue"]]
+ foreach args $cases {
+ test_follow_fork [lindex $args 0] [lindex $args 1] [lindex $args 2]
+ }
I had suggested what Pedro did, but my mail server wasn't too happy with
sending my mails out.
Luis