mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-26 01:07:52 +00:00
Honor detach-on-fork on FreeBSD.
Only detach from the new child process in the follow fork callback if detach_fork is true. gdb/ChangeLog: * fbsd-nat.c (fbsd_follow_fork): Only detach child if "detach_fork" is true.
This commit is contained in:
@@ -826,7 +826,7 @@ static int
|
||||
fbsd_follow_fork (struct target_ops *ops, int follow_child,
|
||||
int detach_fork)
|
||||
{
|
||||
if (!follow_child)
|
||||
if (!follow_child && detach_fork)
|
||||
{
|
||||
struct thread_info *tp = inferior_thread ();
|
||||
pid_t child_pid = ptid_get_pid (tp->pending_follow.value.related_pid);
|
||||
|
||||
Reference in New Issue
Block a user