summaryrefslogtreecommitdiff
path: root/gdb/sparc-nat.c
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@gnu.org>2011-05-21 19:19:44 +0000
committerMark Kettenis <kettenis@gnu.org>2011-05-21 19:19:44 +0000
commit8f6bc56719382004e7715977a83c4c05a32c971b (patch)
tree43ea6bf5fffb73c041e61df68a5c2eb48d8d270e /gdb/sparc-nat.c
parentc201b4b597055397d51d9b80f41b2f1e79c0fd17 (diff)
downloadgdb-8f6bc56719382004e7715977a83c4c05a32c971b.tar.gz
* sparc-nat.c (sparc_fetch_inferior_registers): Explicitly supply
zero as the value for %g0 in the register cache. * sparc-tdep.c (sparc32_supply_gregset): Likewise. * sparc64-tdep.c (sparc64_supply_gregset): Likewise.
Diffstat (limited to 'gdb/sparc-nat.c')
-rw-r--r--gdb/sparc-nat.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gdb/sparc-nat.c b/gdb/sparc-nat.c
index 60d2989e4e2..3d936fcc8fc 100644
--- a/gdb/sparc-nat.c
+++ b/gdb/sparc-nat.c
@@ -159,7 +159,9 @@ sparc_fetch_inferior_registers (struct target_ops *ops,
if (regnum == SPARC_G0_REGNUM)
{
- regcache_raw_supply (regcache, SPARC_G0_REGNUM, NULL);
+ gdb_byte zero[8] = { 0 };
+
+ regcache_raw_supply (regcache, SPARC_G0_REGNUM, &zero);
return;
}