aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorAndrew Cagney <cagney@redhat.com>2004-03-02 02:20:25 +0000
committerAndrew Cagney <cagney@redhat.com>2004-03-02 02:20:25 +0000
commitd4715e41adbde61d0492f7f5e28c47cf655d24e1 (patch)
tree652c83ffe88ebbb1ec93433fc1e5a8e203ef732f /gdb
parent38744d423b276bdbfc32e6694f974d478df77d6d (diff)
downloadgdb-d4715e41adbde61d0492f7f5e28c47cf655d24e1.zip
gdb-d4715e41adbde61d0492f7f5e28c47cf655d24e1.tar.gz
gdb-d4715e41adbde61d0492f7f5e28c47cf655d24e1.tar.bz2
2004-03-01 Andrew Cagney <cagney@redhat.com>
* rs6000-tdep.c (rs6000_init_frame_pc_first): Fix compiler error, use frame_relative_level and get_next_frame.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/rs6000-tdep.c7
2 files changed, 10 insertions, 2 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 4770aa5..ca7fa6d 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2004-03-01 Andrew Cagney <cagney@redhat.com>
+
+ * rs6000-tdep.c (rs6000_init_frame_pc_first): Fix compiler error,
+ use frame_relative_level and get_next_frame.
+
2004-02-29 Andrew Cagney <cagney@redhat.com>
* rs6000-tdep.c (rs6000_init_frame_pc_first): New function.
diff --git a/gdb/rs6000-tdep.c b/gdb/rs6000-tdep.c
index 05eb442..529fb3b 100644
--- a/gdb/rs6000-tdep.c
+++ b/gdb/rs6000-tdep.c
@@ -213,8 +213,11 @@ rs6000_frame_init_saved_regs (struct frame_info *fi)
static CORE_ADDR
rs6000_init_frame_pc_first (int fromleaf, struct frame_info *prev)
{
- return (fromleaf ? DEPRECATED_SAVED_PC_AFTER_CALL (prev->next)
- : prev->next ? DEPRECATED_FRAME_SAVED_PC (prev->next) : read_pc ());
+ return (fromleaf
+ ? DEPRECATED_SAVED_PC_AFTER_CALL (get_next_frame (prev))
+ : frame_relative_level (prev) > 0
+ ? DEPRECATED_FRAME_SAVED_PC (get_next_frame (prev))
+ : read_pc ());
}
static CORE_ADDR