aboutsummaryrefslogtreecommitdiff
path: root/gdb/target-delegates.c
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2013-12-18 14:09:04 -0700
committerTom Tromey <tromey@redhat.com>2014-02-19 07:47:52 -0700
commit959bcd0b393d5d35e7e7b6ac5d8cd6083c866a8c (patch)
tree96923b48437393d05bc826db83fb33f5d825512b /gdb/target-delegates.c
parentafc94e66d421055b1fc13995876c0880c8f626c7 (diff)
downloadgdb-959bcd0b393d5d35e7e7b6ac5d8cd6083c866a8c.zip
gdb-959bcd0b393d5d35e7e7b6ac5d8cd6083c866a8c.tar.gz
gdb-959bcd0b393d5d35e7e7b6ac5d8cd6083c866a8c.tar.bz2
convert to_get_trace_state_variable_value
2014-02-19 Tom Tromey <tromey@redhat.com> * target-delegates.c: Rebuild. * target.c (update_current_target): Don't inherit or default to_get_trace_state_variable_value. * target.h (struct target_ops) <to_get_trace_state_variable_value>: Use TARGET_DEFAULT_RETURN.
Diffstat (limited to 'gdb/target-delegates.c')
-rw-r--r--gdb/target-delegates.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/gdb/target-delegates.c b/gdb/target-delegates.c
index 2fd51e2..4c934e7 100644
--- a/gdb/target-delegates.c
+++ b/gdb/target-delegates.c
@@ -794,6 +794,19 @@ tdefault_trace_find (struct target_ops *self, enum trace_find_type arg1, int ar
}
static int
+delegate_get_trace_state_variable_value (struct target_ops *self, int arg1, LONGEST *arg2)
+{
+ self = self->beneath;
+ return self->to_get_trace_state_variable_value (self, arg1, arg2);
+}
+
+static int
+tdefault_get_trace_state_variable_value (struct target_ops *self, int arg1, LONGEST *arg2)
+{
+ return 0;
+}
+
+static int
delegate_supports_btrace (struct target_ops *self)
{
self = self->beneath;
@@ -945,6 +958,8 @@ install_delegators (struct target_ops *ops)
ops->to_trace_stop = delegate_trace_stop;
if (ops->to_trace_find == NULL)
ops->to_trace_find = delegate_trace_find;
+ if (ops->to_get_trace_state_variable_value == NULL)
+ ops->to_get_trace_state_variable_value = delegate_get_trace_state_variable_value;
if (ops->to_supports_btrace == NULL)
ops->to_supports_btrace = delegate_supports_btrace;
}
@@ -1020,5 +1035,6 @@ install_dummy_methods (struct target_ops *ops)
ops->to_get_tracepoint_status = tdefault_get_tracepoint_status;
ops->to_trace_stop = tdefault_trace_stop;
ops->to_trace_find = tdefault_trace_find;
+ ops->to_get_trace_state_variable_value = tdefault_get_trace_state_variable_value;
ops->to_supports_btrace = tdefault_supports_btrace;
}