diff options
Diffstat (limited to 'gdb/frame.c')
-rw-r--r-- | gdb/frame.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gdb/frame.c b/gdb/frame.c index fff05548261..aaa70daf592 100644 --- a/gdb/frame.c +++ b/gdb/frame.c @@ -682,7 +682,9 @@ do_frame_register_read (void *src, int regnum, gdb_byte *buf) struct regcache * frame_save_as_regcache (struct frame_info *this_frame) { - struct regcache *regcache = regcache_xmalloc (get_frame_arch (this_frame)); + struct address_space *aspace = get_frame_address_space (this_frame); + struct regcache *regcache = regcache_xmalloc (get_frame_arch (this_frame), + aspace); struct cleanup *cleanups = make_cleanup_regcache_xfree (regcache); regcache_save (regcache, do_frame_register_read, this_frame); discard_cleanups (cleanups); |