diff options
author | John Baldwin <jhb@FreeBSD.org> | 2015-04-18 01:00:06 -0400 |
---|---|---|
committer | John Baldwin <jhb@FreeBSD.org> | 2015-04-27 19:27:04 -0400 |
commit | d2b41ca0f9c5641a6b8f42c8013ba042cf5ba120 (patch) | |
tree | e4ec6214fd0de8bd6da6e22dccc084f07dbc6161 /bfd | |
parent | e58e05d677d33da3646721bdd225ec6e90424000 (diff) | |
download | gdb-d2b41ca0f9c5641a6b8f42c8013ba042cf5ba120.zip gdb-d2b41ca0f9c5641a6b8f42c8013ba042cf5ba120.tar.gz gdb-d2b41ca0f9c5641a6b8f42c8013ba042cf5ba120.tar.bz2 |
Add support for catching exec events on FreeBSD.
FreeBSD kernels that support fork tracing always stop a process to
report events for exec. Such a process will have the PL_FLAG_EXEC
flag set in the pl_flags field of the ptrace_lwpinfo struct returned
by PT_LWPINFO. The structure does not include the pathname passed to
exec, so use fbsd_pid_to_exec_file to query the pathname of the
process' executable.
gdb/ChangeLog:
* fbsd-nat.c: (fbsd_wait) [PL_FLAG_EXEC]: Report TARGET_WAITKIND_EXECD
event if PL_FLAG_EXEC is set.
[PL_FLAG_EXEC] (fbsd_insert_exec_catchpoint): New function.
[PL_FLAG_EXEC] (fbsd_remove_exec_catchpoint): New function.
(fbsd_nat_add_target) [PL_FLAG_EXEC]: Set
"to_insert_exec_catchpoint" to "fbsd_insert_exec_catchpoint".
Set "to_remove_exec_catchpoint" to "fbsd_remove_exec_catchpoint".
Diffstat (limited to 'bfd')
0 files changed, 0 insertions, 0 deletions