This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[ob/pushed] Fix ax.c:gdb_eval_agent_expr
- From: Pedro Alves <palves at redhat dot com>
- To: gdb-patches at sourceware dot org
- Date: Sat, 22 Aug 2015 00:00:41 +0100
- Subject: [ob/pushed] Fix ax.c:gdb_eval_agent_expr
- Authentication-results: sourceware.org; auth=none
In C++ mode:
src/gdb/gdbserver/ax.c: In function âeval_result_type gdb_eval_agent_expr(eval_agent_expr_context*, agent_expr*, ULONGEST*)â:
src/gdb/gdbserver/ax.c:1335:11: error: invalid conversion from âintâ to âeval_result_typeâ [-fpermissive]
return 1;
^
"1" as an enum eval_result_type is expr_eval_empty_expression, but
clearly this wants to return expr_eval_unhandled_opcode.
gdb/gdbserver/ChangeLog:
2015-08-21 Pedro Alves <palves@redhat.com>
* ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
instead of literal 1.
---
gdb/gdbserver/ChangeLog | 5 +++++
gdb/gdbserver/ax.c | 2 +-
2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog
index 6103287..cd5e046 100644
--- a/gdb/gdbserver/ChangeLog
+++ b/gdb/gdbserver/ChangeLog
@@ -1,5 +1,10 @@
2015-08-21 Pedro Alves <palves@redhat.com>
+ * ax.c (gdb_eval_agent_expr): Return expr_eval_unhandled_opcode
+ instead of literal 1.
+
+2015-08-21 Pedro Alves <palves@redhat.com>
+
* tdesc.c (default_description): Explicitly zero-initialize.
2015-08-21 Pedro Alves <palves@redhat.com>
diff --git a/gdb/gdbserver/ax.c b/gdb/gdbserver/ax.c
index c5b65fa..f94a27d 100644
--- a/gdb/gdbserver/ax.c
+++ b/gdb/gdbserver/ax.c
@@ -1332,7 +1332,7 @@ gdb_eval_agent_expr (struct eval_agent_expr_context *ctx,
op);
/* If ever GDB generates any of these, we don't have the
option of ignoring. */
- return 1;
+ return expr_eval_unhandled_opcode;
default:
ax_debug ("Agent expression op 0x%x not recognized", op);
--
1.9.3