From: Vladimir Prus <vladimir@codesourcery.com>
To: <gdb@sourceware.org>
Subject: Should detach-on-fork be per-inferiour
Date: Mon, 09 Jul 2012 20:01:00 -0000 [thread overview]
Message-ID: <4FFB3899.3080900@codesourcery.com> (raw)
At present, it seems like 'detach-on-fork' variable is global for GDB instance. Should it be possible to have this variable,
or some other one, working per-inferior. So that, after I attach to a couple of system processes, I can automatically attach
to children spawned by one process but not another?
Here's the output that illustates what I'm talking about:
(gdb) inferior 1
[Switching to inferior 1 [<null>] (<noexec>)]
(gdb) set detach-on-work off
No symbol table is loaded. Use the "file" command.
(gdb) inferior 2
[Switching to inferior 2 [<null>] (<noexec>)]
(gdb) set detach-on-fork on
(gdb) inferior 1
[Switching to inferior 1 [<null>] (<noexec>)]
(gdb) show detach-on-fork
Whether gdb will detach the child of a fork is on.
Thanks,
--
Vladimir Prus
CodeSourcery / Mentor Graphics
http://www.mentor.com/embedded-software/
reply other threads:[~2012-07-09 20:01 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=4FFB3899.3080900@codesourcery.com \
--to=vladimir@codesourcery.com \
--cc=gdb@sourceware.org \
/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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).