This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[commit] fix ARI warnings introduced by ia64-hpux patches


Hello,

There were some ARI violations in the code I recently checked in,
so this patch fixes those.

gdb/ChangeLog:

        * ia64-hpux-nat.c (ia64_hpux_fetch_register): Remove trailing
        new-line at end of warning message.
        (ia64_hpux_store_register): Remove trailing new-line at end of
        error message.
        * ia64-hpux-tdep.c: Rephrase comment.
        * solib-ia64-hpux.c (struct dld_info): Change type of field
        dld_flags from "long long" to ULONGEST.

Tested on ia64-hpux.  Checked in.

---
 gdb/ChangeLog         |   10 ++++++++++
 gdb/ia64-hpux-nat.c   |    4 ++--
 gdb/ia64-hpux-tdep.c  |   10 +++++-----
 gdb/solib-ia64-hpux.c |    4 ++--
 4 files changed, 19 insertions(+), 9 deletions(-)

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 292ce00..59f8e7f 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,13 @@
+2011-01-14  Joel Brobecker  <brobecker@adacore.com>
+
+	* ia64-hpux-nat.c (ia64_hpux_fetch_register): Remove trailing
+	new-line at end of warning message.
+	(ia64_hpux_store_register): Remove trailing new-line at end of
+	error message.
+	* ia64-hpux-tdep.c: Rephrase comment.
+	* solib-ia64-hpux.c (struct dld_info): Change type of field
+	dld_flags from "long long" to ULONGEST.
+
 2011-01-13  Joel Brobecker  <brobecker@adacore.com>
 
 	* hpux-thread.c (hpux_pid_to_str): Delete.
diff --git a/gdb/ia64-hpux-nat.c b/gdb/ia64-hpux-nat.c
index 32160aa..b5c8b80 100644
--- a/gdb/ia64-hpux-nat.c
+++ b/gdb/ia64-hpux-nat.c
@@ -252,7 +252,7 @@ ia64_hpux_fetch_register (struct regcache *regcache, int regnum)
   buf = alloca (len * sizeof (gdb_byte));
   status = ia64_hpux_read_register_from_save_state_t (offset, buf, len);
   if (status < 0)
-    warning (_("Failed to read register value for %s.\n"),
+    warning (_("Failed to read register value for %s."),
              gdbarch_register_name (gdbarch, regnum));
 
   regcache_raw_supply (regcache, regnum, buf);
@@ -312,7 +312,7 @@ ia64_hpux_store_register (const struct regcache *regcache, int regnum)
   status = ia64_hpux_write_register_to_saved_state_t (offset, buf, len);
 
   if (status < 0)
-    error (_("failed to write register value for %s.\n"),
+    error (_("failed to write register value for %s."),
            gdbarch_register_name (gdbarch, regnum));
 }
 
diff --git a/gdb/ia64-hpux-tdep.c b/gdb/ia64-hpux-tdep.c
index c03a00e..e90a450 100644
--- a/gdb/ia64-hpux-tdep.c
+++ b/gdb/ia64-hpux-tdep.c
@@ -36,11 +36,11 @@
    prior to the call, but this does not include stacked registers because
    they are seen by GDB as pseudo registers.
 
-   On Linux, these stacked registers can be saved by simply creating
-   a new register frame, or in other words by moving the BSP.  But the
-   HP/UX kernel does not allow this.  So we rely on this code instead,
-   that makes functions calls whose only purpose is to create new
-   register frames.
+   With Linux kernels, these stacked registers can be saved by simply
+   creating a new register frame, or in other words by moving the BSP.
+   But the HP/UX kernel does not allow this.  So we rely on this code
+   instead, that makes functions calls whose only purpose is to create
+   new register frames.
 
    The array below is the result obtained after assembling the code
    shown below. It's an array of bytes in order to make it independent
diff --git a/gdb/solib-ia64-hpux.c b/gdb/solib-ia64-hpux.c
index 01d44a9..f6dd2dd 100644
--- a/gdb/solib-ia64-hpux.c
+++ b/gdb/solib-ia64-hpux.c
@@ -310,7 +310,7 @@ ia64_hpux_find_start_vma (bfd *abfd, CORE_ADDR *text_start,
 
   for (i = 0; i < i_ehdrp->e_phnum; i++)
     {
-      if (bfd_bread ((PTR) & phdr, sizeof (phdr), abfd) != sizeof (phdr))
+      if (bfd_bread (&phdr, sizeof (phdr), abfd) != sizeof (phdr))
         error (_("failed to read segment %d in %s"), i, abfd->filename);
 
       if (phdr.p_flags & PF_X
@@ -416,7 +416,7 @@ ia64_hpux_get_load_info_addr (void)
 
 struct dld_info
 {
-  long long dld_flags;
+  ULONGEST dld_flags;
   CORE_ADDR load_map;
 };
 
-- 
1.7.0.4


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]