Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/bsd/libproc/dist remove caddr_t
details: https://anonhg.NetBSD.org/src/rev/be800421f064
branches: trunk
changeset: 340715:be800421f064
user: christos <christos%NetBSD.org@localhost>
date: Fri Sep 25 19:09:38 2015 +0000
description:
remove caddr_t
diffstat:
external/bsd/libproc/dist/proc_bkpt.c | 10 +++++-----
external/bsd/libproc/dist/proc_regs.c | 8 ++++----
2 files changed, 9 insertions(+), 9 deletions(-)
diffs (87 lines):
diff -r 4ef44182ffc1 -r be800421f064 external/bsd/libproc/dist/proc_bkpt.c
--- a/external/bsd/libproc/dist/proc_bkpt.c Fri Sep 25 19:08:32 2015 +0000
+++ b/external/bsd/libproc/dist/proc_bkpt.c Fri Sep 25 19:09:38 2015 +0000
@@ -31,7 +31,7 @@
#ifdef __FBSDID
__FBSDID("$FreeBSD: head/lib/libproc/proc_bkpt.c 287106 2015-08-24 12:17:15Z andrew $");
#else
-__RCSID("$NetBSD: proc_bkpt.c,v 1.3 2015/09/25 16:07:32 christos Exp $");
+__RCSID("$NetBSD: proc_bkpt.c,v 1.4 2015/09/25 19:09:38 christos Exp $");
#endif
#include <sys/types.h>
@@ -103,7 +103,7 @@
piod.piod_offs = (void *)caddr;
piod.piod_addr = (void *)saved->data;
piod.piod_len = sizeof(saved->data);
- if (ptrace(PT_IO, proc_getpid(phdl), (caddr_t)&piod, 0) < 0) {
+ if (ptrace(PT_IO, proc_getpid(phdl), &piod, 0) < 0) {
DPRINTF("ERROR: couldn't read instruction at address 0x%"
PRIuPTR, address);
ret = -1;
@@ -117,7 +117,7 @@
piod.piod_offs = (void *)caddr;
piod.piod_addr = (void *)PTRACE_BREAKPOINT;
piod.piod_len = sizeof(PTRACE_BREAKPOINT);
- if (ptrace(PT_IO, proc_getpid(phdl), (caddr_t)&piod, 0) < 0) {
+ if (ptrace(PT_IO, proc_getpid(phdl), &piod, 0) < 0) {
DPRINTF("ERROR: couldn't write instruction at address 0x%"
PRIuPTR, address);
ret = -1;
@@ -163,7 +163,7 @@
piod.piod_offs = (void *)caddr;
piod.piod_addr = (void *)saved->data;
piod.piod_len = sizeof(saved->data);
- if (ptrace(PT_IO, proc_getpid(phdl), (caddr_t)&piod, 0) < 0) {
+ if (ptrace(PT_IO, proc_getpid(phdl), &piod, 0) < 0) {
DPRINTF("ERROR: couldn't write instruction at address 0x%"
PRIuPTR, address);
ret = -1;
@@ -218,7 +218,7 @@
* set up by proc_bkptdel().
*/
proc_regset(phdl, REG_PC, pc);
- if (ptrace(PT_STEP, proc_getpid(phdl), (caddr_t)1, 0) < 0) {
+ if (ptrace(PT_STEP, proc_getpid(phdl), (void *)(intptr_t)1, 0) < 0) {
DPRINTFX("ERROR: ptrace step failed");
return (-1);
}
diff -r 4ef44182ffc1 -r be800421f064 external/bsd/libproc/dist/proc_regs.c
--- a/external/bsd/libproc/dist/proc_regs.c Fri Sep 25 19:08:32 2015 +0000
+++ b/external/bsd/libproc/dist/proc_regs.c Fri Sep 25 19:09:38 2015 +0000
@@ -31,7 +31,7 @@
#ifdef __FBSDID
__FBSDID("$FreeBSD: head/lib/libproc/proc_regs.c 285003 2015-07-01 13:59:26Z br $");
#else
-__RCSID("$NetBSD: proc_regs.c,v 1.3 2015/09/25 16:07:32 christos Exp $");
+__RCSID("$NetBSD: proc_regs.c,v 1.4 2015/09/25 19:09:38 christos Exp $");
#endif
#include <sys/types.h>
@@ -55,7 +55,7 @@
return (-1);
}
memset(®s, 0, sizeof(regs));
- if (ptrace(PT_GETREGS, proc_getpid(phdl), (caddr_t)®s, 0) < 0)
+ if (ptrace(PT_GETREGS, proc_getpid(phdl), ®s, 0) < 0)
return (-1);
switch (reg) {
case REG_PC:
@@ -90,7 +90,7 @@
errno = ENOENT;
return (-1);
}
- if (ptrace(PT_GETREGS, proc_getpid(phdl), (caddr_t)®s, 0) < 0)
+ if (ptrace(PT_GETREGS, proc_getpid(phdl), ®s, 0) < 0)
return (-1);
switch (reg) {
case REG_PC:
@@ -111,7 +111,7 @@
DPRINTFX("ERROR: no support for reg number %d", reg);
return (-1);
}
- if (ptrace(PT_SETREGS, proc_getpid(phdl), (caddr_t)®s, 0) < 0)
+ if (ptrace(PT_SETREGS, proc_getpid(phdl), ®s, 0) < 0)
return (-1);
return (0);
Home |
Main Index |
Thread Index |
Old Index