forked from Imagelibrary/binutils-gdb
* stack.c (print_frame_info_base): Print the frame's pc
only if when print_frame_info_listing_hook is not defined.
This commit is contained in:
@@ -1,3 +1,8 @@
|
|||||||
|
2002-01-13 Keith Seitz <keiths@redhat.com>
|
||||||
|
|
||||||
|
* stack.c (print_frame_info_base): Print the frame's pc
|
||||||
|
only if when print_frame_info_listing_hook is not defined.
|
||||||
|
|
||||||
2002-01-13 Keith Seitz <keiths@redhat.com>
|
2002-01-13 Keith Seitz <keiths@redhat.com>
|
||||||
|
|
||||||
* varobj.c (varobj_set_value): Make sure that there were no
|
* varobj.c (varobj_set_value): Make sure that there were no
|
||||||
|
|||||||
17
gdb/stack.c
17
gdb/stack.c
@@ -399,6 +399,18 @@ print_frame_info_base (struct frame_info *fi, int level, int source, int args)
|
|||||||
fi->pc);
|
fi->pc);
|
||||||
if (!done)
|
if (!done)
|
||||||
{
|
{
|
||||||
|
if (print_frame_info_listing_hook)
|
||||||
|
print_frame_info_listing_hook (sal.symtab, sal.line, sal.line + 1, 0);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
/* We used to do this earlier, but that is clearly
|
||||||
|
wrong. This function is used by many different
|
||||||
|
parts of gdb, including normal_stop in infrun.c,
|
||||||
|
which uses this to print out the current PC
|
||||||
|
when we stepi/nexti into the middle of a source
|
||||||
|
line. Only the command line really wants this
|
||||||
|
behavior. Other UIs probably would like the
|
||||||
|
ability to decide for themselves if it is desired. */
|
||||||
if (addressprint && mid_statement)
|
if (addressprint && mid_statement)
|
||||||
{
|
{
|
||||||
#ifdef UI_OUT
|
#ifdef UI_OUT
|
||||||
@@ -409,11 +421,10 @@ print_frame_info_base (struct frame_info *fi, int level, int source, int args)
|
|||||||
printf_filtered ("\t");
|
printf_filtered ("\t");
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
if (print_frame_info_listing_hook)
|
|
||||||
print_frame_info_listing_hook (sal.symtab, sal.line, sal.line + 1, 0);
|
|
||||||
else
|
|
||||||
print_source_lines (sal.symtab, sal.line, sal.line + 1, 0);
|
print_source_lines (sal.symtab, sal.line, sal.line + 1, 0);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
current_source_line = max (sal.line - lines_to_list / 2, 1);
|
current_source_line = max (sal.line - lines_to_list / 2, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user