]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
dwarflint: Fix reference checking for DW_OP_bra, DW_OP_skip
authorPetr Machata <pmachata@redhat.com>
Mon, 23 Nov 2009 14:48:58 +0000 (15:48 +0100)
committerPetr Machata <pmachata@redhat.com>
Wed, 18 Aug 2010 12:55:13 +0000 (14:55 +0200)
src/dwarflint/low.c

index 18892c7a1e42955bf915f9c77e243e52e1b4fcce..d826b600b897473ba225cc221f3447273f5b4e53 100644 (file)
@@ -1974,7 +1974,10 @@ check_location_expression (struct elf_file *file,
                        ": %s branches before the beginning of location expression.\n",
                        dwarf_locexpr_opcode_string (opcode));
            else
-             ref_record_add (&oprefs, opcode_off + skip, &where);
+             {
+               uint64_t off_after = read_ctx_get_offset (&ctx) + init_off;
+               ref_record_add (&oprefs, off_after + skip, &where);
+             }
 
            break;
          }