From c04b3e8fc5b1096c502afa485cf468054af8c626 Mon Sep 17 00:00:00 2001 From: Jan Kratochvil Date: Mon, 29 Aug 2011 16:55:16 +0000 Subject: [PATCH] gdb/ Fix TUI stepi on code without symbols. * tui/tui-stack.c (tui_show_frame_info): Remove error, set LOW for current PC instead. --- gdb/ChangeLog | 6 ++++++ gdb/tui/tui-stack.c | 7 +++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 790191074c5..2d63c5cc4c5 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2011-08-29 Jan Kratochvil + + Fix TUI stepi on code without symbols. + * tui/tui-stack.c (tui_show_frame_info): Remove error, set LOW for + current PC instead. + 2011-08-28 Jan Kratochvil Code cleanup. diff --git a/gdb/tui/tui-stack.c b/gdb/tui/tui-stack.c index 0068610727d..1ec9bcce653 100644 --- a/gdb/tui/tui-stack.c +++ b/gdb/tui/tui-stack.c @@ -380,8 +380,11 @@ tui_show_frame_info (struct frame_info *fi) { if (find_pc_partial_function (get_frame_pc (fi), (char **) NULL, &low, (CORE_ADDR) 0) == 0) - error (_("No function contains program " - "counter for selected frame.")); + { + /* There is no symbol available for current PC. There is no + safe way how to "disassemble backwards". */ + low = get_frame_pc (fi); + } else low = tui_get_low_disassembly_address (get_frame_arch (fi), low, get_frame_pc (fi)); -- 2.30.2