aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorUlrich Weigand <uweigand@de.ibm.com>2007-07-24 12:49:24 +0000
committerUlrich Weigand <uweigand@de.ibm.com>2007-07-24 12:49:24 +0000
commit98646950ba7fc48d4dc57b3d55be70fdbffee4ab (patch)
treef967655f8a6d73f24690339d198b8a6c144dabf5 /gdb
parent94226e8246cb57e870901213972fb2b32c2afe3f (diff)
downloadgdb-98646950ba7fc48d4dc57b3d55be70fdbffee4ab.zip
gdb-98646950ba7fc48d4dc57b3d55be70fdbffee4ab.tar.gz
gdb-98646950ba7fc48d4dc57b3d55be70fdbffee4ab.tar.bz2
* target.c (memory_xfer_partial): Accesses to unmapped overlay
sections should always go to the executable file.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/target.c8
2 files changed, 13 insertions, 0 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 60f4e9a..5165e0b 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2007-07-24 Ulrich Weigand <uweigand@de.ibm.com>
+
+ * target.c (memory_xfer_partial): Accesses to unmapped overlay
+ sections should always go to the executable file.
+
2004-07-20 Chris Dearman <chris@mips.com>
* mips-tdep.c (heuristic_proc_start): Add more MIPS16 function
diff --git a/gdb/target.c b/gdb/target.c
index 2bb50e6..92a4d6a 100644
--- a/gdb/target.c
+++ b/gdb/target.c
@@ -1017,6 +1017,14 @@ memory_xfer_partial (struct target_ops *ops, void *readbuf, const void *writebuf
return xfer_memory (memaddr, readbuf, len, 0, NULL, ops);
}
+ /* Likewise for accesses to unmapped overlay sections. */
+ if (readbuf != NULL && overlay_debugging)
+ {
+ asection *section = find_pc_overlay (memaddr);
+ if (pc_in_unmapped_range (memaddr, section))
+ return xfer_memory (memaddr, readbuf, len, 0, NULL, ops);
+ }
+
/* Try GDB's internal data cache. */
region = lookup_mem_region (memaddr);
/* region->hi == 0 means there's no upper bound. */