[commit] Remove unnecessary cast in aix-thread.c:ptrace32.
Joel Brobecker
brobecker@adacore.com
Fri Oct 4 08:52:00 GMT 2013
Hello,
I just happened to notice this while investigating something else...
We're casting "addr" into "addr_ptr", but this variable is actually
a parameter with that very same type...
gdb/ChangeLog:
* aix-thread.c (ptrace32): Remove cast to addr_ptr.
Tested on ppc-aix, checked in.
--
Joel
---
gdb/ChangeLog | 4 ++++
gdb/aix-thread.c | 2 +-
2 files changed, 5 insertions(+), 1 deletion(-)
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 1f88eb6..52454ae 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,9 @@
2013-10-04 Joel Brobecker <brobecker@adacore.com>
+ * aix-thread.c (ptrace32): Remove cast to addr_ptr.
+
+2013-10-04 Joel Brobecker <brobecker@adacore.com>
+
* mi/mi-main.c (run_one_inferior): Add function description.
Make ARG a pointer to an integer whose value determines whether
we should "run" or "start" the program.
diff --git a/gdb/aix-thread.c b/gdb/aix-thread.c
index 97a5ab3..31c14e0 100644
--- a/gdb/aix-thread.c
+++ b/gdb/aix-thread.c
@@ -264,7 +264,7 @@ ptrace32 (int req, int id, addr_ptr addr, int data, int *buf)
{
errno = 0;
return ptrace_check (req, id,
- ptrace (req, id, (addr_ptr) addr, data, buf));
+ ptrace (req, id, addr, data, buf));
}
/* If *PIDP is a composite process/thread id, convert it to a
--
1.8.1.2
More information about the Gdb-patches
mailing list