]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
* readelf.c (decode_location_expression): Sign extend value for
authorAlan Modra <amodra@gmail.com>
Sun, 12 Sep 2004 05:52:44 +0000 (05:52 +0000)
committerAlan Modra <amodra@gmail.com>
Sun, 12 Sep 2004 05:52:44 +0000 (05:52 +0000)
DW_OP_const1s, DW_OP_const2s, DW_OP_const4s, DW_OP_bra, DW_OP_skip.

binutils/ChangeLog
binutils/readelf.c

index 93f96d71d8be4ea54947ae1d380ea2235c404d2b..f1f374f66cb1234f0442634435ca7f687ab76c8d 100644 (file)
@@ -1,3 +1,8 @@
+2004-09-12  Alan Modra  <amodra@bigpond.net.au>
+
+       * readelf.c (decode_location_expression): Sign extend value for
+       DW_OP_const1s, DW_OP_const2s, DW_OP_const4s, DW_OP_bra, DW_OP_skip.
+
 2004-09-09  Nick Clifton  <nickc@redhat.com>
 
        PR 363
@@ -10,8 +15,8 @@
 
 2004-09-06  Danny Smith  <dannysmith@users.sourceforge.net>
 
-        * doc/binutils.texi (dlltool): Update --add-underscore, --kill-at
-        documentation.
+       * doc/binutils.texi (dlltool): Update --add-underscore, --kill-at
+       documentation.
 
 2004-09-06  Michael Wardle  <mbw@endbracket.net>
 
@@ -23,7 +28,7 @@
        * dlltool.c (make_one_lib_file): Test if internal_name was
        specified by user before using it.
 
-2004-09-02  Carlo Wood  <carlo@alinoe.com> 
+2004-09-02  Carlo Wood  <carlo@alinoe.com>
 
        PR binutils/351
        * dlltool.c (make_one_lib_file): For IDATA6 take the name from
index bf8409352cd2415d82fc607804deeb678840c4e2..6b03b23d6cecc73ceb73bd363f22361a2133e41a 100644 (file)
@@ -1,5 +1,6 @@
 /* readelf.c -- display contents of an ELF format file
-   Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+   Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004
+   Free Software Foundation, Inc.
 
    Originally developed by Eric Youngdale <eric@andante.jic.com>
    Modifications by Nick Clifton <nickc@redhat.com>
@@ -23,7 +24,7 @@
 \f
 /* The difference between readelf and objdump:
 
-  Both programs are capabale of displaying the contents of ELF format files,
+  Both programs are capable of displaying the contents of ELF format files,
   so why does the binutils project have two file dumpers ?
 
   The reason is that objdump sees an ELF file through a BFD filter of the
@@ -7670,14 +7671,14 @@ decode_location_expression (unsigned char * data,
          printf ("DW_OP_const1u: %lu", (unsigned long) byte_get (data++, 1));
          break;
        case DW_OP_const1s:
-         printf ("DW_OP_const1s: %ld", (long) byte_get (data++, 1));
+         printf ("DW_OP_const1s: %ld", (long) byte_get_signed (data++, 1));
          break;
        case DW_OP_const2u:
          printf ("DW_OP_const2u: %lu", (unsigned long) byte_get (data, 2));
          data += 2;
          break;
        case DW_OP_const2s:
-         printf ("DW_OP_const2s: %ld", (long) byte_get (data, 2));
+         printf ("DW_OP_const2s: %ld", (long) byte_get_signed (data, 2));
          data += 2;
          break;
        case DW_OP_const4u:
@@ -7685,7 +7686,7 @@ decode_location_expression (unsigned char * data,
          data += 4;
          break;
        case DW_OP_const4s:
-         printf ("DW_OP_const4s: %ld", (long) byte_get (data, 4));
+         printf ("DW_OP_const4s: %ld", (long) byte_get_signed (data, 4));
          data += 4;
          break;
        case DW_OP_const8u:
@@ -7775,7 +7776,7 @@ decode_location_expression (unsigned char * data,
          printf ("DW_OP_xor");
          break;
        case DW_OP_bra:
-         printf ("DW_OP_bra: %ld", (long) byte_get (data, 2));
+         printf ("DW_OP_bra: %ld", (long) byte_get_signed (data, 2));
          data += 2;
          break;
        case DW_OP_eq:
@@ -7797,7 +7798,7 @@ decode_location_expression (unsigned char * data,
          printf ("DW_OP_ne");
          break;
        case DW_OP_skip:
-         printf ("DW_OP_skip: %ld", (long) byte_get (data, 2));
+         printf ("DW_OP_skip: %ld", (long) byte_get_signed (data, 2));
          data += 2;
          break;