This is the mail archive of the
insight@sources.redhat.com
mailing list for the Insight project.
[ob] Don't access `struct frame_info' internals
- From: Andrew Cagney <ac131313 at redhat dot com>
- To: insight at sources dot redhat dot com
- Date: Fri, 11 Apr 2003 13:42:21 -0400
- Subject: [ob] Don't access `struct frame_info' internals
FYI,
This stops insight trying to access the internals of a `struct
frame_info'. Also fixes a build problem.
committed,
Andrew
2003-04-11 Andrew Cagney <cagney at redhat dot com>
* generic/gdbtk-stack.c (get_frame_name): Use get_frame_pc and
get_next_frame.
Index: generic/gdbtk-stack.c
===================================================================
RCS file: /cvs/src/src/gdb/gdbtk/generic/gdbtk-stack.c,v
retrieving revision 1.17
diff -u -r1.17 gdbtk-stack.c
--- generic/gdbtk-stack.c 25 Feb 2003 21:36:22 -0000 1.17
+++ generic/gdbtk-stack.c 11 Apr 2003 16:31:35 -0000
@@ -544,15 +544,15 @@
}
sal =
- find_pc_line (fi->pc,
- fi->next != NULL
+ find_pc_line (get_frame_pc (fi),
+ get_next_frame (fi) != NULL
&& !(get_frame_type (fi) == SIGTRAMP_FRAME)
&& !(get_frame_type (fi) == DUMMY_FRAME));
- func = find_pc_function (fi->pc);
+ func = find_pc_function (get_frame_pc (fi));
if (func)
{
- struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (fi->pc);
+ struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (get_frame_pc (fi));
if (msymbol != NULL
&& (SYMBOL_VALUE_ADDRESS (msymbol)
> BLOCK_START (SYMBOL_BLOCK_VALUE (func))))
@@ -569,7 +569,7 @@
}
else
{
- struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (fi->pc);
+ struct minimal_symbol *msymbol = lookup_minimal_symbol_by_pc (get_frame_pc (fi));
if (msymbol != NULL)
{
funname = GDBTK_SYMBOL_SOURCE_NAME (msymbol);
@@ -608,7 +608,7 @@
#ifdef PC_SOLIB
if (!funname)
{
- char *lib = PC_SOLIB (fi->pc);
+ char *lib = PC_SOLIB (get_frame_pc (fi));
if (lib)
{
Tcl_AppendStringsToObj (objv[0], " from ", lib, (char *) NULL);