aboutsummaryrefslogtreecommitdiff
path: root/gdb/regcache.c
diff options
context:
space:
mode:
authorJim Blandy <jimb@codesourcery.com>2004-08-04 17:50:55 +0000
committerJim Blandy <jimb@codesourcery.com>2004-08-04 17:50:55 +0000
commit7ab3286fbed75475c383ae77aa909aa5efd7dac4 (patch)
treeb1eb459de12c1756a7162ed9e1efa357d8697b66 /gdb/regcache.c
parent870d65d5f61aa7596e9e175bed580f123e7a8da0 (diff)
downloadgdb-7ab3286fbed75475c383ae77aa909aa5efd7dac4.zip
gdb-7ab3286fbed75475c383ae77aa909aa5efd7dac4.tar.gz
gdb-7ab3286fbed75475c383ae77aa909aa5efd7dac4.tar.bz2
* regcache.c (regcache_raw_read): Assert that, after calling
target_fetch_registers, the register we're reading is cached.
Diffstat (limited to 'gdb/regcache.c')
-rw-r--r--gdb/regcache.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gdb/regcache.c b/gdb/regcache.c
index b45740d..411392c 100644
--- a/gdb/regcache.c
+++ b/gdb/regcache.c
@@ -614,6 +614,7 @@ regcache_raw_read (struct regcache *regcache, int regnum, void *buf)
}
if (!register_cached (regnum))
target_fetch_registers (regnum);
+ gdb_assert (register_cached (regnum));
}
/* Copy the value directly into the register cache. */
memcpy (buf, register_buffer (regcache, regnum),