From a6a25f5e2664872f2c3de707fffcb1669b03aeb1 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Sun, 17 Dec 2023 12:15:00 -0700 Subject: Remove redundant check from tui_refresh_frame_and_register_information tui_refresh_frame_and_register_information checks 'from_stack' in a block that's already guarded by a 'from_stack' check. This patch removes the redundant check. Tested-By: Tom de Vries Reviewed-By: Andrew Burgess Approved-By: Andrew Burgess --- gdb/tui/tui-hooks.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'gdb') diff --git a/gdb/tui/tui-hooks.c b/gdb/tui/tui-hooks.c index 3a4eda9..fc7ffb4 100644 --- a/gdb/tui/tui-hooks.c +++ b/gdb/tui/tui-hooks.c @@ -132,11 +132,10 @@ tui_refresh_frame_and_register_information () /* Display the frame position (even if there is no symbols or the PC is not known). */ - bool frame_info_changed_p = tui_show_frame_info (fi); + tui_show_frame_info (fi); /* Refresh the register window if it's visible. */ - if (tui_is_window_visible (DATA_WIN) - && (frame_info_changed_p || from_stack)) + if (tui_is_window_visible (DATA_WIN)) TUI_DATA_WIN->check_register_values (fi); } else if (!from_stack) -- cgit v1.1