diff options
author | Mark Kettenis <kettenis@gnu.org> | 2005-08-13 22:03:46 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@gnu.org> | 2005-08-13 22:03:46 +0000 |
commit | 8d815b630982cd3ec29d6f2ca3abf680acd7b141 (patch) | |
tree | b4417f82eecb91456a07052a5d39d329efa24e22 /gdb/i386-linux-nat.c | |
parent | ad0c136aa79dc2308bd1c311798d44992a53a9d1 (diff) | |
download | gdb-8d815b630982cd3ec29d6f2ca3abf680acd7b141.tar.gz |
* i386-linux-nat.c (fetch_register, store_register)
(supply_gregset, fill_gregset): Remove redundant casts.
Diffstat (limited to 'gdb/i386-linux-nat.c')
-rw-r--r-- | gdb/i386-linux-nat.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/gdb/i386-linux-nat.c b/gdb/i386-linux-nat.c index b6c669119a2..2037a899d52 100644 --- a/gdb/i386-linux-nat.c +++ b/gdb/i386-linux-nat.c @@ -1,6 +1,7 @@ /* Native-dependent code for GNU/Linux i386. - Copyright 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc. + Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005 + Free Software Foundation, Inc. This file is part of GDB. @@ -183,7 +184,7 @@ fetch_register (int regno) error (_("Couldn't read register %s (#%d): %s."), REGISTER_NAME (regno), regno, safe_strerror (errno)); - regcache_raw_supply (current_regcache, regno, (gdb_byte *) &val); + regcache_raw_supply (current_regcache, regno, &val); } /* Store one register. */ @@ -204,7 +205,7 @@ store_register (int regno) tid = PIDGET (inferior_ptid); /* Not a threaded program. */ errno = 0; - regcache_raw_collect (current_regcache, regno, (gdb_byte *) &val); + regcache_raw_collect (current_regcache, regno, &val); ptrace (PTRACE_POKEUSER, tid, register_addr (regno, 0), val); if (errno != 0) error (_("Couldn't write register %s (#%d): %s."), REGISTER_NAME (regno), @@ -225,11 +226,11 @@ supply_gregset (elf_gregset_t *gregsetp) int i; for (i = 0; i < I386_NUM_GREGS; i++) - regcache_raw_supply (current_regcache, i, (gdb_byte *) (regp + regmap[i])); + regcache_raw_supply (current_regcache, i, regp + regmap[i]); if (I386_LINUX_ORIG_EAX_REGNUM < NUM_REGS) regcache_raw_supply (current_regcache, I386_LINUX_ORIG_EAX_REGNUM, - (gdb_byte *) (regp + ORIG_EAX)); + regp + ORIG_EAX); } /* Fill register REGNO (if it is a general-purpose register) in @@ -244,12 +245,12 @@ fill_gregset (elf_gregset_t *gregsetp, int regno) for (i = 0; i < I386_NUM_GREGS; i++) if (regno == -1 || regno == i) - regcache_raw_collect (current_regcache, i, (gdb_byte *) (regp + regmap[i])); + regcache_raw_collect (current_regcache, i, regp + regmap[i]); if ((regno == -1 || regno == I386_LINUX_ORIG_EAX_REGNUM) && I386_LINUX_ORIG_EAX_REGNUM < NUM_REGS) regcache_raw_collect (current_regcache, I386_LINUX_ORIG_EAX_REGNUM, - (gdb_byte *) (regp + ORIG_EAX)); + regp + ORIG_EAX); } #ifdef HAVE_PTRACE_GETREGS |