@@ -302,3 +302,8 @@ This observer is used for internal testing. Do not use.
See testsuite/gdb.gdb/observer.exp.
@end deftypefun
+@deftypefun void target_thread_changed (ptid_t @var{somearg})
+The target has changed its current thread to ptid_t. Used by LKD and called
+by the shtdi and remote interfaces.
+@end deftypefun
+
@@ -2162,6 +2162,8 @@ static void
set_general_thread (struct ptid ptid)
{
set_thread (ptid, 1);
+
+ observer_notify_target_thread_changed (ptid);
}
static void
@@ -7071,6 +7073,8 @@ remote_wait (struct target_ops *ops,
mark_async_event_handler (remote_async_inferior_event_token);
}
+ observer_notify_target_thread_changed (event_ptid);
+
return event_ptid;
}