aboutsummaryrefslogtreecommitdiff
path: root/gdb/target.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/target.c')
-rw-r--r--gdb/target.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gdb/target.c b/gdb/target.c
index d0aa8f5..0cebecf 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -2469,6 +2469,8 @@ target_pre_inferior (int from_tty)
current_inferior ()->highest_thread_num = 0;
+ update_previous_thread ();
+
agent_capability_invalidate ();
}
@@ -2497,6 +2499,9 @@ target_preopen (int from_tty)
error (_("Program not killed."));
}
+ /* Release reference to old previous thread. */
+ update_previous_thread ();
+
/* Calling target_kill may remove the target from the stack. But if
it doesn't (which seems like a win for UDI), remove it now. */
/* Leave the exec target, though. The user may be switching from a