aboutsummaryrefslogtreecommitdiff
path: root/gdb/i386mach-nat.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/i386mach-nat.c')
-rw-r--r--gdb/i386mach-nat.c27
1 files changed, 14 insertions, 13 deletions
diff --git a/gdb/i386mach-nat.c b/gdb/i386mach-nat.c
index 52081c7..4e2d323 100644
--- a/gdb/i386mach-nat.c
+++ b/gdb/i386mach-nat.c
@@ -53,12 +53,13 @@ fetch_inferior_registers (regno)
ptrace (PTRACE_GETFPREGS, inferior_pid,
(PTRACE_ARG3_TYPE) &inferior_fp_registers);
- bcopy (&inferior_registers, registers, sizeof inferior_registers);
+ memcpy (registers, &inferior_registers, sizeof inferior_registers);
- bcopy (inferior_fp_registers.f_st,&registers[REGISTER_BYTE (FP0_REGNUM)],
+ memcpy (&registers[REGISTER_BYTE (FP0_REGNUM)],
+ inferior_fp_registers.f_st,
sizeof inferior_fp_registers.f_st);
- bcopy (&inferior_fp_registers.f_ctrl,
- &registers[REGISTER_BYTE (FPC_REGNUM)],
+ memcpy (&registers[REGISTER_BYTE (FPC_REGNUM)],
+ &inferior_fp_registers.f_ctrl,
sizeof inferior_fp_registers - sizeof inferior_fp_registers.f_st);
}
@@ -74,12 +75,12 @@ store_inferior_registers (regno)
struct fp_state inferior_fp_registers;
extern char registers[];
- bcopy (registers, &inferior_registers, 20 * 4);
+ memcpy (&inferior_registers, registers, 20 * 4);
- bcopy (&registers[REGISTER_BYTE (FP0_REGNUM)],inferior_fp_registers.f_st,
+ memcpy (inferior_fp_registers.f_st,&registers[REGISTER_BYTE (FP0_REGNUM)],
sizeof inferior_fp_registers.f_st);
- bcopy (&registers[REGISTER_BYTE (FPC_REGNUM)],
- &inferior_fp_registers.f_ctrl,
+ memcpy (&inferior_fp_registers.f_ctrl,
+ &registers[REGISTER_BYTE (FPC_REGNUM)],
sizeof inferior_fp_registers - sizeof inferior_fp_registers.f_st);
#ifdef PTRACE_FP_BUG
@@ -125,18 +126,18 @@ fetch_core_registers (core_reg_sect, core_reg_size, which, reg_addr)
switch (which) {
case 0:
case 1:
- bcopy (core_reg_sect, registers, core_reg_size);
+ memcpy (registers, core_reg_sect, core_reg_size);
break;
case 2:
#ifdef FP0_REGNUM
- bcopy (core_reg_sect,
- &registers[REGISTER_BYTE (FP0_REGNUM)],
+ memcpy (&registers[REGISTER_BYTE (FP0_REGNUM)],
+ core_reg_sect,
core_reg_size); /* FIXME, probably bogus */
#endif
#ifdef FPC_REGNUM
- bcopy (&corestr.c_fpu.f_fpstatus.f_ctrl,
- &registers[REGISTER_BYTE (FPC_REGNUM)],
+ memcpy (&registers[REGISTER_BYTE (FPC_REGNUM)],
+ &corestr.c_fpu.f_fpstatus.f_ctrl,
sizeof corestr.c_fpu.f_fpstatus -
sizeof corestr.c_fpu.f_fpstatus.f_st);
#endif