diff options
author | John Baldwin <jhb@FreeBSD.org> | 2016-07-15 17:01:21 -0700 |
---|---|---|
committer | John Baldwin <jhb@FreeBSD.org> | 2016-07-20 11:01:45 -0700 |
commit | 5fa14c6b9789bad6f91dd21889f7b1a0eb75c6d0 (patch) | |
tree | faa481c214f61f81f5a245fc580ecc8d792f3f9a /gdb/fbsd-nat.c | |
parent | da95a26cc381c0f092f515ffe108075985c16d7f (diff) | |
download | gdb-5fa14c6b9789bad6f91dd21889f7b1a0eb75c6d0.zip gdb-5fa14c6b9789bad6f91dd21889f7b1a0eb75c6d0.tar.gz gdb-5fa14c6b9789bad6f91dd21889f7b1a0eb75c6d0.tar.bz2 |
Enable ptrace events on new child processes.
New child processes on FreeBSD do not inherit optional ptrace events
such as fork and LWP events from the parent process. Instead,
explicitly enable events on new children when reporting a fork
event.
gdb/ChangeLog:
* fbsd-nat.c (fbsd_wait): Use "fbsd_enable_proc_events" on
new child processes.
Diffstat (limited to 'gdb/fbsd-nat.c')
-rw-r--r-- | gdb/fbsd-nat.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/gdb/fbsd-nat.c b/gdb/fbsd-nat.c index 508ab19..5e4304e 100644 --- a/gdb/fbsd-nat.c +++ b/gdb/fbsd-nat.c @@ -836,6 +836,9 @@ fbsd_wait (struct target_ops *ops, child_ptid = ptid_build (child, pl.pl_lwpid, 0); } + /* Enable additional events on the child process. */ + fbsd_enable_proc_events (ptid_get_pid (child_ptid)); + /* For vfork, the child process will have the P_PPWAIT flag set. */ fbsd_fetch_kinfo_proc (child, &kp); |