* dwarf2loc.c (disassemble_dwarf_expression): Fix instruction
authorTom Tromey <tromey@redhat.com>
Fri, 13 May 2011 18:42:48 +0000 (18:42 +0000)
committerTom Tromey <tromey@redhat.com>
Fri, 13 May 2011 18:42:48 +0000 (18:42 +0000)
offset display.

gdb/ChangeLog
gdb/dwarf2loc.c

index 65d92b5bb7917edb851913b2742aea0c2a0869d6..4ee52d53ee1047a133626b26bb34447770238e33 100644 (file)
@@ -1,3 +1,8 @@
+2011-05-13  Tom Tromey  <tromey@redhat.com>
+
+       * dwarf2loc.c (disassemble_dwarf_expression): Fix instruction
+       offset display.
+
 2011-05-13  Doug Evans  <dje@google.com>
 
        * linux-nat.c (debug_linux_nat_async): Delete.
index 64cc5e553c8d2ad5eebb6ae43a502b96115c1abc..9afb186a5d2d14313841a3f1dc0cfaaf96fbfdfe 100644 (file)
@@ -2364,8 +2364,8 @@ disassemble_dwarf_expression (struct ui_file *stream,
 
       if (!name)
        error (_("Unrecognized DWARF opcode 0x%02x at %ld"),
-              op, (long) (data - start));
-      fprintf_filtered (stream, "  % 4ld: %s", (long) (data - start), name);
+              op, (long) (data - 1 - start));
+      fprintf_filtered (stream, "  % 4ld: %s", (long) (data - 1 - start), name);
 
       switch (op)
        {