]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
Remove redundant check from tui_refresh_frame_and_register_information
authorTom Tromey <tom@tromey.com>
Sun, 17 Dec 2023 19:15:00 +0000 (12:15 -0700)
committerTom Tromey <tom@tromey.com>
Thu, 8 Feb 2024 19:16:07 +0000 (12:16 -0700)
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 <tdevries@suse.de>
Reviewed-By: Andrew Burgess <aburgess@redhat.com>
Approved-By: Andrew Burgess <aburgess@redhat.com>
gdb/tui/tui-hooks.c

index 3a4eda91aa3ec3ea6cf720680ac98a2e0e2e7419..fc7ffb4f202e6ef3d44e932ea6e67dbe2cc4ee73 100644 (file)
@@ -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)