From 5428d89199e54028de6e030718de1c5d538c1294 Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Sat, 2 Sep 2006 09:43:17 +0000 Subject: (linux_nat_mourn_inferior): Destroy thread. Clear any pending events --- gdb/linux-nat.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c index b37f203..6925bfe 100644 --- a/gdb/linux-nat.c +++ b/gdb/linux-nat.c @@ -2381,6 +2381,9 @@ linux_nat_mourn_inferior (void) { trap_ptid = null_ptid; + if (target_can_async_p ()) + gdb_inferior_destroy (gdb_status); + /* Destroy LWP info; it's no longer valid. */ init_lwp_list (); @@ -2396,6 +2399,8 @@ linux_nat_mourn_inferior (void) there are other viable forks to debug. Delete the exiting one and context-switch to the first available. */ linux_fork_mourn_inferior (); + + if (target_can_async_p ()) gdb_clear_pending_events (); } static LONGEST -- cgit v1.1