2008-08-18 Pedro Alves <pedro@codesourcery.com>

gdb/doc/
	* observer.texi (thread_ptid_changed): New.

	gdb/
	* gdbthread.h (thread_change_ptid): Declare.
	* infrun.c (infrun_thread_ptid_changed): New.
	(_initialize_infrun): Attach infrun_thread_ptid_changed to the
	thread_ptid_changed observer.
	* regcache.c (regcache_thread_ptid_changed): New.
	(_initialize_regcache): Attach regcache_thread_ptid_changed to the
	thread_ptid_changed observer.
	* thread.c (thread_change_ptid): New.
This commit is contained in:
Pedro Alves
2008-08-18 22:35:17 +00:00
parent f98dfd4b46
commit 5231c1fd73
7 changed files with 68 additions and 0 deletions

View File

@@ -588,6 +588,15 @@ prune_threads (void)
}
}
void
thread_change_ptid (ptid_t old_ptid, ptid_t new_ptid)
{
struct thread_info * tp = find_thread_pid (old_ptid);
tp->ptid = new_ptid;
observer_notify_thread_ptid_changed (old_ptid, new_ptid);
}
void
set_running (ptid_t ptid, int running)
{