From 2cdfa11333867dbfcb2a6b631cda989d64f68944 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Mon, 1 Jul 2019 00:51:20 -0600 Subject: [PATCH] Change tui_get_register to return void tui_get_register returns a tui_status, but nothing checks this, so it can return void instead. gdb/ChangeLog 2019-07-17 Tom Tromey * tui/tui-regs.c (tui_get_register): Return void. --- gdb/ChangeLog | 4 ++++ gdb/tui/tui-regs.c | 13 ++++--------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 0de9c33e362..8de1558eea2 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,7 @@ +2019-07-17 Tom Tromey + + * tui/tui-regs.c (tui_get_register): Return void. + 2019-07-17 Tom Tromey * tui/tui-wingeneral.c (tui_gen_win_info::make_visible): diff --git a/gdb/tui/tui-regs.c b/gdb/tui/tui-regs.c index 382a44126d3..52f67026b54 100644 --- a/gdb/tui/tui-regs.c +++ b/gdb/tui/tui-regs.c @@ -54,9 +54,9 @@ static void tui_show_register_group (tui_data_window *win_info, struct frame_info *frame, int refresh_values_only); -static enum tui_status tui_get_register (struct frame_info *frame, - struct tui_data_item_window *data, - int regnum, bool *changedp); +static void tui_get_register (struct frame_info *frame, + struct tui_data_item_window *data, + int regnum, bool *changedp); @@ -646,13 +646,11 @@ tui_register_format (struct frame_info *frame, int regnum) /* Get the register value from the given frame and format it for the display. When changep is set, check if the new register value has changed with respect to the previous call. */ -static enum tui_status +static void tui_get_register (struct frame_info *frame, struct tui_data_item_window *data, int regnum, bool *changedp) { - enum tui_status ret = TUI_FAILURE; - if (changedp) *changedp = false; if (target_has_registers) @@ -666,8 +664,5 @@ tui_get_register (struct frame_info *frame, *changedp = true; xfree (prev_content); - - ret = TUI_SUCCESS; } - return ret; } -- 2.30.2