diff options
Diffstat (limited to 'gdb')
-rw-r--r-- | gdb/ChangeLog | 12 | ||||
-rw-r--r-- | gdb/inf-child.c | 2 | ||||
-rw-r--r-- | gdb/inf-ptrace.c | 2 | ||||
-rw-r--r-- | gdb/linux-nat.c | 2 | ||||
-rw-r--r-- | gdb/nto-procfs.c | 2 | ||||
-rw-r--r-- | gdb/spu-linux-nat.c | 2 | ||||
-rw-r--r-- | gdb/target.c | 6 | ||||
-rw-r--r-- | gdb/target.h | 4 |
8 files changed, 22 insertions, 10 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index a98901b..96d6e58 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,17 @@ 2014-02-19 Tom Tromey <tromey@redhat.com> + * target.h (struct target_ops) <to_post_attach>: Add argument. + (target_post_attach): Add argument. + * target.c (debug_to_post_attach): Add argument. + (update_current_target): Update. + * spu-linux-nat.c (spu_child_post_attach): Add 'self' argument. + * nto-procfs.c (procfs_post_attach): Add 'self' argument. + * linux-nat.c (linux_child_post_attach): Add 'self' argument. + * inf-ptrace.c (inf_ptrace_post_attach): Add 'self' argument. + * inf-child.c (inf_child_post_attach): Add 'self' argument. + +2014-02-19 Tom Tromey <tromey@redhat.com> + * windows-nat.c (windows_close): Add 'self' argument. * tracepoint.c (tfile_close): Add 'self' argument. * target.h (struct target_ops) <to_close>: Add argument. diff --git a/gdb/inf-child.c b/gdb/inf-child.c index 549e44a..c142912 100644 --- a/gdb/inf-child.c +++ b/gdb/inf-child.c @@ -87,7 +87,7 @@ inf_child_store_inferior_registers (struct target_ops *ops, } static void -inf_child_post_attach (int pid) +inf_child_post_attach (struct target_ops *self, int pid) { /* This version of Unix doesn't require a meaningful "post attach" operation by a debugger. */ diff --git a/gdb/inf-ptrace.c b/gdb/inf-ptrace.c index 1269d24..ac4d2a4 100644 --- a/gdb/inf-ptrace.c +++ b/gdb/inf-ptrace.c @@ -246,7 +246,7 @@ inf_ptrace_attach (struct target_ops *ops, char *args, int from_tty) #ifdef PT_GET_PROCESS_STATE static void -inf_ptrace_post_attach (int pid) +inf_ptrace_post_attach (struct target_ops *self, int pid) { ptrace_event_t pe; diff --git a/gdb/linux-nat.c b/gdb/linux-nat.c index a76ba30..a6118af 100644 --- a/gdb/linux-nat.c +++ b/gdb/linux-nat.c @@ -329,7 +329,7 @@ linux_init_ptrace (pid_t pid) } static void -linux_child_post_attach (int pid) +linux_child_post_attach (struct target_ops *self, int pid) { linux_init_ptrace (pid); } diff --git a/gdb/nto-procfs.c b/gdb/nto-procfs.c index 7739197c..9fab861 100644 --- a/gdb/nto-procfs.c +++ b/gdb/nto-procfs.c @@ -648,7 +648,7 @@ procfs_attach (struct target_ops *ops, char *args, int from_tty) } static void -procfs_post_attach (pid_t pid) +procfs_post_attach (struct target_ops *self, pid_t pid) { if (exec_bfd) solib_create_inferior_hook (0); diff --git a/gdb/spu-linux-nat.c b/gdb/spu-linux-nat.c index a68e4e0..71c1643 100644 --- a/gdb/spu-linux-nat.c +++ b/gdb/spu-linux-nat.c @@ -420,7 +420,7 @@ spu_child_post_startup_inferior (ptid_t ptid) /* Override the post_attach routine to try load the SPE executable file image from its copy inside the target process. */ static void -spu_child_post_attach (int pid) +spu_child_post_attach (struct target_ops *self, int pid) { int fd; ULONGEST addr; diff --git a/gdb/target.c b/gdb/target.c index e63725a..73531e1 100644 --- a/gdb/target.c +++ b/gdb/target.c @@ -721,7 +721,7 @@ update_current_target (void) (void (*) (struct target_ops *)) target_ignore); de_fault (to_post_attach, - (void (*) (int)) + (void (*) (struct target_ops *, int)) target_ignore); de_fault (to_prepare_to_store, (void (*) (struct target_ops *, struct regcache *)) @@ -3914,9 +3914,9 @@ target_stop (ptid_t ptid) } static void -debug_to_post_attach (int pid) +debug_to_post_attach (struct target_ops *self, int pid) { - debug_target.to_post_attach (pid); + debug_target.to_post_attach (&debug_target, pid); fprintf_unfiltered (gdb_stdlog, "target_post_attach (%d)\n", pid); } diff --git a/gdb/target.h b/gdb/target.h index 125d649..1e8d612 100644 --- a/gdb/target.h +++ b/gdb/target.h @@ -404,7 +404,7 @@ struct target_ops void (*to_xclose) (struct target_ops *targ); void (*to_close) (struct target_ops *); void (*to_attach) (struct target_ops *ops, char *, int); - void (*to_post_attach) (int); + void (*to_post_attach) (struct target_ops *, int); void (*to_detach) (struct target_ops *ops, const char *, int); void (*to_disconnect) (struct target_ops *, char *, int); void (*to_resume) (struct target_ops *, ptid_t, int, enum gdb_signal) @@ -1019,7 +1019,7 @@ void target_attach (char *, int); This operation provides a target-specific hook that allows the necessary bookkeeping to be performed after an attach completes. */ #define target_post_attach(pid) \ - (*current_target.to_post_attach) (pid) + (*current_target.to_post_attach) (¤t_target, pid) /* Takes a program previously attached to and detaches it. The program may resume execution (some targets do, some don't) and will |