From 89681c5ea6177f0ec1b6222479789706e3330b44 Mon Sep 17 00:00:00 2001 From: Pedro Alves Date: Thu, 1 May 2008 22:48:49 +0000 Subject: [PATCH] * linux-nat.c (linux_nat_switch_fork): Reinit GDB's thread list and register the fork's PTID as a thread. --- gdb/ChangeLog | 5 +++++ gdb/linux-nat.c | 2 ++ 2 files changed, 7 insertions(+) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 8f614d98ba..b45350a97d 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2008-05-01 Pedro Alves + + * linux-nat.c (linux_nat_switch_fork): Reinit GDB's thread list + and register the fork's PTID as a thread. + 2008-05-01 Aleksandar Ristovski PR gdb/1665 diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c index b09cd49896..246712cb5a 100644 --- a/gdb/linux-nat.c +++ b/gdb/linux-nat.c @@ -973,8 +973,10 @@ linux_nat_switch_fork (ptid_t new_ptid) { struct lwp_info *lp; + init_thread_list (); init_lwp_list (); lp = add_lwp (new_ptid); + add_thread_silent (new_ptid); lp->stopped = 1; } -- 2.11.0