aboutsummaryrefslogtreecommitdiff
path: root/gdb/hppa-tdep.c
diff options
context:
space:
mode:
authorJim Kingdon <jkingdon@engr.sgi.com>1993-07-26 19:19:39 +0000
committerJim Kingdon <jkingdon@engr.sgi.com>1993-07-26 19:19:39 +0000
commit08ecd8f3d858acd15a276e80e3de5f5a95996709 (patch)
treec7ab5a80ebce6c07a099f721d3eec9335dde3a42 /gdb/hppa-tdep.c
parentb3024965a065723fcebf545e31cff2d778888e84 (diff)
downloadgdb-08ecd8f3d858acd15a276e80e3de5f5a95996709.zip
gdb-08ecd8f3d858acd15a276e80e3de5f5a95996709.tar.gz
gdb-08ecd8f3d858acd15a276e80e3de5f5a95996709.tar.bz2
* hppa-tdep.c (pc_in_linker_stub): Return 0 if can't read memory.
Diffstat (limited to 'gdb/hppa-tdep.c')
-rw-r--r--gdb/hppa-tdep.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gdb/hppa-tdep.c b/gdb/hppa-tdep.c
index 885f6db..5b11159 100644
--- a/gdb/hppa-tdep.c
+++ b/gdb/hppa-tdep.c
@@ -306,6 +306,11 @@ pc_in_linker_stub (pc)
{
int found_magic_instruction = 0;
int i;
+ char buf[4];
+
+ /* If unable to read memory, assume pc is not in a linker stub. */
+ if (target_read_memory (pc, buf, 4) != 0)
+ return 0;
/* We are looking for something like