+2014-02-19 Tom Tromey <tromey@redhat.com>
+
+ * target.h (struct target_ops) <to_pass_signals>: Add argument.
+ * target.c (target_pass_signals): Add argument.
+ * remote.c (remote_pass_signals): Add 'self' argument.
+ (remote_start_remote): Update.
+ * procfs.c (procfs_pass_signals): Add 'self' argument.
+ * nto-procfs.c (procfs_pass_signals): Add 'self' argument.
+ * linux-nat.c (linux_nat_pass_signals): Add 'self' argument.
+ (linux_nat_create_inferior, linux_nat_attach): Update.
+
2014-02-19 Tom Tromey <tromey@redhat.com>
* windows-nat.c (windows_can_run): Add 'self' argument.
/* Update signals to pass to the inferior. */
static void
-linux_nat_pass_signals (int numsigs, unsigned char *pass_signals)
+linux_nat_pass_signals (struct target_ops *self,
+ int numsigs, unsigned char *pass_signals)
{
int signo;
#endif /* HAVE_PERSONALITY */
/* Make sure we report all signals during startup. */
- linux_nat_pass_signals (0, NULL);
+ linux_nat_pass_signals (ops, 0, NULL);
linux_ops->to_create_inferior (ops, exec_file, allargs, env, from_tty);
volatile struct gdb_exception ex;
/* Make sure we report all signals during attach. */
- linux_nat_pass_signals (0, NULL);
+ linux_nat_pass_signals (ops, 0, NULL);
TRY_CATCH (ex, RETURN_MASK_ERROR)
{
/* Set list of signals to be handled in the target. */
static void
-procfs_pass_signals (int numsigs, unsigned char *pass_signals)
+procfs_pass_signals (struct target_ops *self,
+ int numsigs, unsigned char *pass_signals)
{
int signo;
struct regcache *, int);
static void procfs_store_registers (struct target_ops *,
struct regcache *, int);
-static void procfs_pass_signals (int, unsigned char *);
+static void procfs_pass_signals (struct target_ops *self,
+ int, unsigned char *);
static void procfs_kill_inferior (struct target_ops *ops);
static void procfs_mourn_inferior (struct target_ops *ops);
static void procfs_create_inferior (struct target_ops *, char *,
/* Set up to trace signals in the child process. */
static void
-procfs_pass_signals (int numsigs, unsigned char *pass_signals)
+procfs_pass_signals (struct target_ops *self,
+ int numsigs, unsigned char *pass_signals)
{
gdb_sigset_t signals;
procinfo *pi = find_procinfo_or_die (ptid_get_pid (inferior_ptid), 0);
it can simply pass through to the inferior without reporting. */
static void
-remote_pass_signals (int numsigs, unsigned char *pass_signals)
+remote_pass_signals (struct target_ops *self,
+ int numsigs, unsigned char *pass_signals)
{
if (remote_protocol_packets[PACKET_QPassSignals].support != PACKET_DISABLE)
{
gdb_assert (wait_status == NULL);
/* Report all signals during attach/startup. */
- remote_pass_signals (0, NULL);
+ remote_pass_signals (target, 0, NULL);
}
/* If we connected to a live target, do some additional setup. */
fprintf_unfiltered (gdb_stdlog, " })\n");
}
- (*t->to_pass_signals) (numsigs, pass_signals);
+ (*t->to_pass_signals) (t, numsigs, pass_signals);
return;
}
}
/* Documentation of this routine is provided with the corresponding
target_* macro. */
- void (*to_pass_signals) (int, unsigned char *);
+ void (*to_pass_signals) (struct target_ops *, int, unsigned char *);
/* Documentation of this routine is provided with the
corresponding target_* function. */