aboutsummaryrefslogtreecommitdiff
path: root/gdb/fork-child.c
diff options
context:
space:
mode:
authorStu Grossman <grossman@cygnus>1993-10-16 06:42:02 +0000
committerStu Grossman <grossman@cygnus>1993-10-16 06:42:02 +0000
commitde43d7d0059427148461aede30bb07db993fae4b (patch)
tree7493430c03b1b15dafcb1b30ce320969e701b3ba /gdb/fork-child.c
parent9bc3153e824a67812ebbc67431b9e1fd033d6d4b (diff)
downloadgdb-de43d7d0059427148461aede30bb07db993fae4b.zip
gdb-de43d7d0059427148461aede30bb07db993fae4b.tar.gz
gdb-de43d7d0059427148461aede30bb07db993fae4b.tar.bz2
* breakpoint.c (breakpoint_thread_match break_command_1):
Thread-specific breakpoint support. * breakpoint.h (struct breakpoint): Add thread id field. * fork-child.c (fork_inferior): Move call to init_thread_list() back a bit so that init_trace_fun can do thread functions. * hppa-tdep.c (restore_pc_queue): Add pid to call to target_wait. * hppab-nat.c (child_resume): Handle default pid. * hppah-nat.c (child_resume): Handle default pid. * i386lynx-nat.c (child_wait): New arg pid. * inflow.c (kill_command): Reset thread list. * infptrace.c (child_resume): Handle default pid. * infrun.c: Thread-specific breakpoint support. * inftarg.c (child_wait): Add pid arg. * osfsolib.c (solib_create_inferior_hook): Add pid to call to target_resume. * procfs.c: Multi-thread support. * remote-bug.c (bug_wait): Add pid arg. * remote-hms.c (hms_wait): Add pid arg. * remote-mips.c (mips_wait): Add pid arg. * remote-mon.c (monitor_wait): Add pid arg. * remote-nindy.c (nindy_wait): Add pid arg. * remote-sim.c (gdbsim_wait): Add pid arg. * remote-udi.c (udi_wait): Add pid arg. * remote-vx.c (vx_wait): Add pid arg. * remote-z8k.c (sim_wait): Add pid arg. * remote.c (remote_wait): Add pid arg. * solib.c (solib_create_inferior_hook): Add pid to call to target_resume. * target.h (struct target_ops): Add pid arg to to_wait and to_notice_signals. * thread.c (valid_thread_id): New func to validate thread #s. * (pid_to_thread_id): New func to do the obvious. * thread.h: Prototypes for above. * coff-solib.c (coff_solib_add): Use nameoffset field to locate filename.
Diffstat (limited to 'gdb/fork-child.c')
-rw-r--r--gdb/fork-child.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gdb/fork-child.c b/gdb/fork-child.c
index e982864..9aa3cfe 100644
--- a/gdb/fork-child.c
+++ b/gdb/fork-child.c
@@ -238,11 +238,15 @@ fork_inferior (exec_file, allargs, env, traceme_fun, init_trace_fun)
/* Restore our environment in case a vforked child clob'd it. */
environ = save_our_env;
+ init_thread_list();
+
/* Now that we have a child process, make it our target, and
initialize anything target-vector-specific that needs initializing. */
(*init_trace_fun)(pid);
- init_thread_list();
+#ifdef CREATE_INFERIOR_HOOK
+ CREATE_INFERIOR_HOOK (pid);
+#endif
/* The process was started by the fork that created it,
but it will have stopped one instruction after execing the shell.