+2014-02-19 Tom Tromey <tromey@redhat.com>
+
+ * target.h (struct target_ops) <to_terminal_inferior>: Add
+ argument.
+ * target.c (target_terminal_inferior): Add argument.
+ (update_current_target): Update.
+ * remote.c (remote_terminal_inferior): Add 'self' argument.
+ * linux-nat.c (linux_nat_terminal_inferior): Add 'self' argument.
+ * inflow.c (terminal_inferior): Add 'self' argument.
+ * inferior.h (terminal_inferior): Add 'self' argument.
+ * go32-nat.c (go32_terminal_inferior): Add 'self' argument.
+ (go32_terminal_inferior): Add 'self' argument.
+
2014-02-19 Tom Tromey <tromey@redhat.com>
* target.h (struct target_ops) <to_terminal_init>: Add argument.
}
static void
-go32_terminal_inferior (void)
+go32_terminal_inferior (struct target_ops *self)
{
/* Redirect standard handles as child wants them. */
errno = 0;
extern void terminal_ours_for_output (void);
-extern void terminal_inferior (void);
+extern void terminal_inferior (struct target_ops *self);
extern void terminal_init_inferior (struct target_ops *self);
This is preparation for starting or resuming the inferior. */
void
-terminal_inferior (void)
+terminal_inferior (struct target_ops *self)
{
struct inferior *inf;
struct terminal_info *tinfo;
/* target_terminal_inferior implementation. */
static void
-linux_nat_terminal_inferior (void)
+linux_nat_terminal_inferior (struct target_ops *self)
{
if (!target_is_async_p ())
{
/* Async mode is disabled. */
- terminal_inferior ();
+ terminal_inferior (self);
return;
}
- terminal_inferior ();
+ terminal_inferior (self);
/* Calls to target_terminal_*() are meant to be idempotent. */
if (!async_terminal_is_ours)
is required. */
static void
-remote_terminal_inferior (void)
+remote_terminal_inferior (struct target_ops *self)
{
if (!target_async_permitted)
/* Nothing to do. */
static void debug_to_terminal_init (struct target_ops *self);
-static void debug_to_terminal_inferior (void);
+static void debug_to_terminal_inferior (struct target_ops *self);
static void debug_to_terminal_ours_for_output (void);
/* If GDB is resuming the inferior in the foreground, install
inferior's terminal modes. */
- (*current_target.to_terminal_inferior) ();
+ (*current_target.to_terminal_inferior) (¤t_target);
}
static int
(void (*) (struct target_ops *))
target_ignore);
de_fault (to_terminal_inferior,
- (void (*) (void))
+ (void (*) (struct target_ops *))
target_ignore);
de_fault (to_terminal_ours_for_output,
(void (*) (void))
}
static void
-debug_to_terminal_inferior (void)
+debug_to_terminal_inferior (struct target_ops *self)
{
- debug_target.to_terminal_inferior ();
+ debug_target.to_terminal_inferior (&debug_target);
fprintf_unfiltered (gdb_stdlog, "target_terminal_inferior ()\n");
}
int (*to_masked_watch_num_registers) (struct target_ops *,
CORE_ADDR, CORE_ADDR);
void (*to_terminal_init) (struct target_ops *);
- void (*to_terminal_inferior) (void);
+ void (*to_terminal_inferior) (struct target_ops *);
void (*to_terminal_ours_for_output) (void);
void (*to_terminal_ours) (void);
void (*to_terminal_save_ours) (void);