+2014-02-19 Tom Tromey <tromey@redhat.com>
+
+ * target.h (struct target_ops)
+ <to_supports_disable_randomization>: Add argument.
+ * target.c (find_default_supports_disable_randomization): Add
+ argument.
+ (target_supports_disable_randomization): Add argument.
+ (find_default_supports_disable_randomization): Add 'self'
+ argument.
+ * remote.c (extended_remote_supports_disable_randomization): Add
+ 'self' argument.
+ (remote_supports_disable_randomization): Add 'self' argument.
+ (extended_remote_create_inferior): Update.
+ * linux-nat.c (linux_nat_supports_disable_randomization): Add
+ 'self' argument.
+
2014-02-19 Tom Tromey <tromey@redhat.com>
* target.h (struct target_ops)
}
static int
-linux_nat_supports_disable_randomization (void)
+linux_nat_supports_disable_randomization (struct target_ops *self)
{
#ifdef HAVE_PERSONALITY
return 1;
}
static int
-extended_remote_supports_disable_randomization (void)
+extended_remote_supports_disable_randomization (struct target_ops *self)
{
return (remote_protocol_packets[PACKET_QDisableRandomization].support
== PACKET_ENABLE);
target_async (inferior_event_handler, 0);
/* Disable address space randomization if requested (and supported). */
- if (extended_remote_supports_disable_randomization ())
+ if (extended_remote_supports_disable_randomization (ops))
extended_remote_disable_randomization (disable_randomization);
/* Now restart the remote server. */
}
static int
-remote_supports_disable_randomization (void)
+remote_supports_disable_randomization (struct target_ops *self)
{
/* Only supported in extended mode. */
return 0;
}
static int
-find_default_supports_disable_randomization (void)
+find_default_supports_disable_randomization (struct target_ops *self)
{
struct target_ops *t;
t = find_default_run_target (NULL);
if (t && t->to_supports_disable_randomization)
- return (t->to_supports_disable_randomization) ();
+ return (t->to_supports_disable_randomization) (t);
return 0;
}
for (t = ¤t_target; t != NULL; t = t->beneath)
if (t->to_supports_disable_randomization)
- return t->to_supports_disable_randomization ();
+ return t->to_supports_disable_randomization (t);
return 0;
}
int (*to_supports_enable_disable_tracepoint) (struct target_ops *);
/* Does this target support disabling address space randomization? */
- int (*to_supports_disable_randomization) (void);
+ int (*to_supports_disable_randomization) (struct target_ops *);
/* Does this target support the tracenz bytecode for string collection? */
int (*to_supports_string_tracing) (void);