* [dw-op-value] fix a bad compare
@ 2009-09-02 21:10 Tom Tromey
0 siblings, 0 replies; only message in thread
From: Tom Tromey @ 2009-09-02 21:10 UTC (permalink / raw)
To: Project Archer
I ran into this bug when writing a test case for submitting this branch
upstream.
There was an incorrect comparison in the code, causing us to reject
certain expressions.
Tom
2009-09-02 Tom Tromey <tromey@redhat.com>
* dwarf2expr.c (execute_stack_op) <DW_OP_implicit_value>: Fix
test.
diff --git a/gdb/dwarf2expr.c b/gdb/dwarf2expr.c
index a673939..7b788b9 100644
--- a/gdb/dwarf2expr.c
+++ b/gdb/dwarf2expr.c
@@ -456,7 +456,7 @@ execute_stack_op (struct dwarf_expr_context *ctx,
{
ULONGEST len;
op_ptr = read_uleb128 (op_ptr, op_end, &len);
- if (op_ptr + len >= op_end)
+ if (op_ptr + len > op_end)
error (_("DW_OP_implicit_value: too few bytes available."));
ctx->len = len;
ctx->data = op_ptr;
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2009-09-02 21:10 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-02 21:10 [dw-op-value] fix a bad compare Tom Tromey
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).