]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
ppc-linux-tdep.c: Wrong signness for buffer holding instructions.
authorPedro Alves <palves@redhat.com>
Fri, 19 Apr 2013 15:22:14 +0000 (15:22 +0000)
committerPedro Alves <palves@redhat.com>
Fri, 19 Apr 2013 15:22:14 +0000 (15:22 +0000)
There seems to be no reason for this buffer to be signed.  We pass it
around to functions expecting it to be unsigned (which triggers
-Wpointer-sign warnings).

gdb/
2013-04-19  Pedro Alves  <palves@redhat.com>

* ppc-linux-tdep.c (ppc_skip_trampoline_code): Change local
'insnbuf' buffer type to unsigned int[].

gdb/ChangeLog
gdb/ppc-linux-tdep.c

index 9314749344faa916ed77ef835785c95f21dbd1ea..f71ebc640453d1da7d4748679f6838ff1ccf1fe1 100644 (file)
@@ -1,3 +1,8 @@
+2013-04-19  Pedro Alves  <palves@redhat.com>
+
+       * ppc-linux-tdep.c (ppc_skip_trampoline_code): Change local
+       'insnbuf' buffer type to unsigned int[].
+
 2013-04-19  Pedro Alves  <palves@redhat.com>
 
        * mips-tdep.c (mips_read_pc): Change local 'pc' type to LONGEST.
index 6895562a782a43333c25cfd8f07afdbce05d8bfd..25b6c0b9102398b71682ae1124cddfcabf70ec2c 100644 (file)
@@ -355,7 +355,7 @@ powerpc_linux_in_dynsym_resolve_code (CORE_ADDR pc)
 static CORE_ADDR
 ppc_skip_trampoline_code (struct frame_info *frame, CORE_ADDR pc)
 {
-  int insnbuf[POWERPC32_PLT_STUB_LEN];
+  unsigned int insnbuf[POWERPC32_PLT_STUB_LEN];
   struct gdbarch *gdbarch = get_frame_arch (frame);
   struct gdbarch_tdep *tdep = gdbarch_tdep (gdbarch);
   enum bfd_endian byte_order = gdbarch_byte_order (gdbarch);