aboutsummaryrefslogtreecommitdiff
path: root/gdb/ultra3-xdep.c
diff options
context:
space:
mode:
authorFred Fish <fnf@specifix.com>1992-06-24 04:49:48 +0000
committerFred Fish <fnf@specifix.com>1992-06-24 04:49:48 +0000
commite676a15f0b9ef089973311249917e203917b3903 (patch)
treeac8656c9b5795932c78ea01ea53ce9eabee5a9ae /gdb/ultra3-xdep.c
parent0fd24984ce2d13dd7ec231afa5b42e60ff1f1858 (diff)
downloadgdb-e676a15f0b9ef089973311249917e203917b3903.zip
gdb-e676a15f0b9ef089973311249917e203917b3903.tar.gz
gdb-e676a15f0b9ef089973311249917e203917b3903.tar.bz2
* Makefile.in (VERSION): Bump to 4.5.6.
* coffread.c (coff_end_symtab): Cast 2nd arg of complain() to correct type. * defs.h (NORETURN): Define away for Lucid compiler. * remote.c (remote_timer, remote_interrupt): Signal handlers take one int arg. * ser-termios.c (serial_write, serial_close): Return whatever value the write/close call returns, rather than falling off end. * inferior.h (PTRACE_ARG3_TYPE): Third arg to ptrace is int on more systems than it is "char *". Define PTRACE_ARG3_TYPE to default to int. * infptrace.c, hppabsd-xdep.c, hppahpux-xdep.c, i386-xdep.c, inferior.h (call_ptrace): Use PTRACE_ARG3_TYPE to declare type of third arg. * a68v-xdep.c, arm-xdep.c, convex-xdep.c, hp300ux-xdep.c, infrun.c, m88k-xdep.c, mach386-xdep.c, mips-xdep.c, os68k-xdep.c, pyr-tdep.c, pyr-xdep.c, rs6000-xdep.c, sparc-xdep.c, sun3-xdep.c, sun386-xdep.c, symm-xdep.c, ultra3-xdep.c: Use PTRACE_ARG3_TYPE to cast ptrace argument 3. * sparc-xdep.c, a68v-xdep.c (fetch_inferior_registers, store_inferior_registers): Supply missing fourth argument to ptrace().
Diffstat (limited to 'gdb/ultra3-xdep.c')
-rw-r--r--gdb/ultra3-xdep.c26
1 files changed, 16 insertions, 10 deletions
diff --git a/gdb/ultra3-xdep.c b/gdb/ultra3-xdep.c
index 82ad286..3fff182 100644
--- a/gdb/ultra3-xdep.c
+++ b/gdb/ultra3-xdep.c
@@ -72,7 +72,8 @@ fetch_register (regno)
supply_register (regno, &val);
} else {
errno = 0;
- val = ptrace (PT_READ_U, inferior_pid, (int*)register_addr(regno,0), 0);
+ val = ptrace (PT_READ_U, inferior_pid,
+ (PTRACE_ARG3_TYPE) register_addr(regno,0), 0);
if (errno != 0) {
sprintf(buf,"reading register %s (#%d)",reg_names[regno],regno);
perror_with_name (buf);
@@ -103,8 +104,9 @@ fetch_inferior_registers (regno)
/* Global Registers */
#ifdef ULTRA3
errno = 0;
- ptrace (PT_READ_STRUCT, inferior_pid, (int*)register_addr(GR96_REGNUM,0),
- (int)&pt_struct.pt_gr[0], 32*4);
+ ptrace (PT_READ_STRUCT, inferior_pid,
+ (PTRACE_ARG3_TYPE) register_addr(GR96_REGNUM,0),
+ (int)&pt_struct.pt_gr[0], 32*4);
if (errno != 0) {
perror_with_name ("reading global registers");
ret_val = -1;
@@ -119,8 +121,9 @@ fetch_inferior_registers (regno)
/* Local Registers */
#ifdef ULTRA3
errno = 0;
- ptrace (PT_READ_STRUCT, inferior_pid, (int*)register_addr(LR0_REGNUM,0),
- (int)&pt_struct.pt_lr[0], 128*4);
+ ptrace (PT_READ_STRUCT, inferior_pid,
+ (PTRACE_ARG3_TYPE) register_addr(LR0_REGNUM,0),
+ (int)&pt_struct.pt_lr[0], 128*4);
if (errno != 0) {
perror_with_name ("reading local registers");
ret_val = -1;
@@ -168,7 +171,8 @@ store_inferior_registers (regno)
return;
regaddr = register_addr (regno, 0);
errno = 0;
- ptrace (PT_WRITE_U, inferior_pid,(int*)regaddr,read_register(regno));
+ ptrace (PT_WRITE_U, inferior_pid,
+ (PTRACE_ARG3_TYPE) regaddr, read_register(regno));
if (errno != 0)
{
sprintf (buf, "writing register %s (#%d)", reg_names[regno],regno);
@@ -184,8 +188,9 @@ store_inferior_registers (regno)
for (regno = LR0_REGNUM; regno < LR0_REGNUM+128; regno++)
pt_struct.pt_gr[regno] = read_register(regno);
errno = 0;
- ptrace (PT_WRITE_STRUCT, inferior_pid, (int*)register_addr(GR1_REGNUM,0),
- (int)&pt_struct.pt_gr1,(1*32*128)*4);
+ ptrace (PT_WRITE_STRUCT, inferior_pid,
+ (PTRACE_ARG3_TYPE) register_addr(GR1_REGNUM,0),
+ (int)&pt_struct.pt_gr1,(1*32*128)*4);
if (errno != 0)
{
sprintf (buf, "writing all local/global registers");
@@ -202,8 +207,9 @@ store_inferior_registers (regno)
pt_struct.pt_bp = read_register(BP_REGNUM);
pt_struct.pt_fc = read_register(FC_REGNUM);
errno = 0;
- ptrace (PT_WRITE_STRUCT, inferior_pid, (int*)register_addr(CPS_REGNUM,0),
- (int)&pt_struct.pt_psr,(10)*4);
+ ptrace (PT_WRITE_STRUCT, inferior_pid,
+ (PTRACE_ARG3_TYPE) register_addr(CPS_REGNUM,0),
+ (int)&pt_struct.pt_psr,(10)*4);
if (errno != 0)
{
sprintf (buf, "writing all special registers");