Mirror of the gdb mailing list
 help / color / mirror / Atom feed
From: Richard <rgrdev@googlemail.com>
To: Richard <rgrdev@gmail.com>
Cc: gdb@sources.redhat.com
Subject: Re: fork debugging : back to parent.
Date: Mon, 07 Aug 2006 21:47:00 -0000	[thread overview]
Message-ID: <87slk8xlpk.fsf@mail.com> (raw)
In-Reply-To: <20060807210740.GA28579@nevyn.them.org> (Daniel Jacobowitz's 	message of "Mon, 7 Aug 2006 17:07:40 -0400")


I have version 6.5.5 just build and confirmed with "show version"

,----
| show version
| GNU gdb 6.5.50.20060806
| Copyright (C) 2006 Free Software Foundation, Inc.
| GDB is free software, covered by the GNU General Public License, and you are
| welcome to change it and/or distribute copies of it under certain conditions.
| Type "show copying" to see the conditions.
| There is absolutely no warranty for GDB.  Type "show warranty" for details.
| This GDB was configured as "i686-pc-linux-gnu".
| >
`----

set follow-fork-mode to both is not supported:

,----
| >help set follow
| Set debugger response to a program call of fork or vfork.
| A fork or vfork creates a new process.  follow-fork-mode can be:
|   parent  - the original process is debugged after a fork
|   child   - the new process is debugged after a fork
| The unfollowed process will continue to run.
| By default, the debugger will follow the parent process.
| >set follow-fork-mode both
| Undefined item: "both".
| >set follow-fork-mode child
| >
`----

Sorry, if I'm missing something obvious. How owuld I browse "recent
features" in CVS?

Daniel Jacobowitz <drow@false.org> writes:

> On Mon, Aug 07, 2006 at 01:21:02PM -0700, Richard (sent by Nabble.com) wrote:
>> 
>> Below is the code from "Advanced programming in the Unix environment". if I
>> set follow-fork to child, I can step ok to the exclp line. But how do I get
>> back to debugging the parent process? Is it possible? I tried setting
>> follow-fork back to "parent" and then "c"ontinuing but no joy.  or do I have
>> to specifically save process ids and reattach to the parent process?
>
> Try using a recent version of GDB, and set follow-fork-mode to "both".
> This was added in GDB 6.5.
>
> -- 
> Daniel Jacobowitz
> CodeSourcery
>

-- 


  reply	other threads:[~2006-08-07 21:47 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-07 20:21 Richard (sent by Nabble.com)
2006-08-07 21:07 ` Daniel Jacobowitz
2006-08-07 21:47   ` Richard [this message]
2006-08-08  0:04     ` Daniel Jacobowitz
2006-08-08  7:27       ` Richard
2006-08-08  8:49       ` Richard
2006-08-08 13:16         ` Daniel Jacobowitz
2006-08-10 21:06 ` Richard
2006-08-10 21:39   ` Daniel Jacobowitz
2006-08-10 22:06     ` Richard
2006-08-10 22:10       ` Daniel Jacobowitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87slk8xlpk.fsf@mail.com \
    --to=rgrdev@googlemail.com \
    --cc=gdb@sources.redhat.com \
    --cc=rgrdev@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox