diff options
Diffstat (limited to 'gdb/tui')
-rw-r--r-- | gdb/tui/tui-command.c | 2 | ||||
-rw-r--r-- | gdb/tui/tui-disasm.c | 6 | ||||
-rw-r--r-- | gdb/tui/tui-file.c | 2 | ||||
-rw-r--r-- | gdb/tui/tui-io.c | 14 | ||||
-rw-r--r-- | gdb/tui/tui-layout.c | 4 | ||||
-rw-r--r-- | gdb/tui/tui-regs.c | 8 | ||||
-rw-r--r-- | gdb/tui/tui-source.c | 8 | ||||
-rw-r--r-- | gdb/tui/tui-stack.c | 4 | ||||
-rw-r--r-- | gdb/tui/tui-win.c | 6 | ||||
-rw-r--r-- | gdb/tui/tui-winsource.c | 8 | ||||
-rw-r--r-- | gdb/tui/tui.c | 4 |
11 files changed, 31 insertions, 35 deletions
diff --git a/gdb/tui/tui-command.c b/gdb/tui/tui-command.c index c3a9b5c1d01..a182b4ce8e6 100644 --- a/gdb/tui/tui-command.c +++ b/gdb/tui/tui-command.c @@ -65,7 +65,7 @@ tui_dispatch_ctrl_char (unsigned int ch) else { unsigned int c = 0, ch_copy = ch; - register int i; + int i; char *term; /* If this is an xterm, page next/prev keys aren't returned diff --git a/gdb/tui/tui-disasm.c b/gdb/tui/tui-disasm.c index 6258032af49..a4311218dcc 100644 --- a/gdb/tui/tui-disasm.c +++ b/gdb/tui/tui-disasm.c @@ -95,7 +95,7 @@ tui_disassemble (struct tui_asm_line* lines, CORE_ADDR pc, int count) static CORE_ADDR tui_find_disassembly_address (CORE_ADDR pc, int from) { - register CORE_ADDR new_low; + CORE_ADDR new_low; int max_lines; int i; struct tui_asm_line* lines; @@ -176,9 +176,9 @@ enum tui_status tui_set_disassem_content (CORE_ADDR pc) { enum tui_status ret = TUI_FAILURE; - register int i; + int i; int offset = TUI_DISASM_WIN->detail.source_info.horizontal_offset; - register int line_width, max_lines; + int line_width, max_lines; CORE_ADDR cur_pc; struct tui_gen_win_info * locator = tui_locator_win_info_ptr (); int tab_len = tui_default_tab_len (); diff --git a/gdb/tui/tui-file.c b/gdb/tui/tui-file.c index 36fc097029c..5d2740ef066 100644 --- a/gdb/tui/tui-file.c +++ b/gdb/tui/tui-file.c @@ -25,7 +25,7 @@ #include "tui.h" -#include <string.h> +#include "gdb_string.h" /* A ``struct ui_file'' that is compatible with all the legacy code. */ diff --git a/gdb/tui/tui-io.c b/gdb/tui/tui-io.c index 559ff454a4d..6ca2beeb85e 100644 --- a/gdb/tui/tui-io.c +++ b/gdb/tui/tui-io.c @@ -322,8 +322,7 @@ tui_readline_output (int code, gdb_client_data data) Comes from readline/complete.c */ static char * -printable_part (pathname) - char *pathname; +printable_part (char *pathname) { char *temp; @@ -360,8 +359,7 @@ printable_part (pathname) } while (0) static int -print_filename (to_print, full_pathname) - char *to_print, *full_pathname; +print_filename (char *to_print, char *full_pathname) { int printed_len = 0; char *s; @@ -376,7 +374,7 @@ print_filename (to_print, full_pathname) /* The user must press "y" or "n". Non-zero return means "y" pressed. Comes from readline/complete.c */ static int -get_y_or_n () +get_y_or_n (void) { extern int _rl_abort_internal (); int c; @@ -402,9 +400,7 @@ get_y_or_n () Comes from readline/complete.c and modified to write in the TUI command window using tui_putc/tui_puts. */ static void -tui_rl_display_match_list (matches, len, max) - char **matches; - int len, max; +tui_rl_display_match_list (char **matches, int len, int max) { typedef int QSFUNC (const void *, const void *); extern int _rl_qsort_string_compare (const void*, const void*); @@ -598,7 +594,7 @@ tui_cont_sig (int sig) /* Initialize the IO for gdb in curses mode. */ void -tui_initialize_io () +tui_initialize_io (void) { #ifdef SIGCONT signal (SIGCONT, tui_cont_sig); diff --git a/gdb/tui/tui-layout.c b/gdb/tui/tui-layout.c index 0cd71f70f6e..341d3cd3e14 100644 --- a/gdb/tui/tui-layout.c +++ b/gdb/tui/tui-layout.c @@ -418,8 +418,8 @@ tui_set_layout_for_display_command (const char *layout_name) if (layout_name != (char *) NULL) { - register int i; - register char *buf_ptr; + int i; + char *buf_ptr; enum tui_layout_type new_layout = UNDEFINED_LAYOUT; enum tui_register_display_type dpy_type = TUI_UNDEFINED_REGS; enum tui_layout_type cur_layout = tui_current_layout (); diff --git a/gdb/tui/tui-regs.c b/gdb/tui/tui-regs.c index 3dc01e6df26..d3ff1ebb648 100644 --- a/gdb/tui/tui-regs.c +++ b/gdb/tui/tui-regs.c @@ -111,7 +111,7 @@ static void tui_scroll_regs_backward_command (char *, int); int tui_last_regs_line_no (void) { - register int num_lines = (-1); + int num_lines = (-1); if (TUI_DATA_WIN->detail.data_display_info.regs_content_count > 0) { @@ -282,7 +282,7 @@ tui_display_registers_from (int start_element_no) if (TUI_DATA_WIN->detail.data_display_info.regs_content != (tui_win_content) NULL && TUI_DATA_WIN->detail.data_display_info.regs_content_count > 0) { - register int i = start_element_no; + int i = start_element_no; int j, value_chars_wide, item_win_width, cur_y, label_width; enum precision_type precision; @@ -367,11 +367,11 @@ tui_display_reg_element_at_line (int start_element_no, int start_line_no) if (TUI_DATA_WIN->detail.data_display_info.regs_content != (tui_win_content) NULL && TUI_DATA_WIN->detail.data_display_info.regs_content_count > 0) { - register int element_no = start_element_no; + int element_no = start_element_no; if (start_element_no != 0 && start_line_no != 0) { - register int last_line_no, first_line_on_last_page; + int last_line_no, first_line_on_last_page; last_line_no = tui_last_regs_line_no (); first_line_on_last_page = last_line_no - (TUI_DATA_WIN->generic.height - 2); diff --git a/gdb/tui/tui-source.c b/gdb/tui/tui-source.c index db8d04033bb..f97de2f49e3 100644 --- a/gdb/tui/tui-source.c +++ b/gdb/tui/tui-source.c @@ -52,9 +52,9 @@ tui_set_source_content (struct symtab *s, int line_no, int noerror) if (s != (struct symtab *) NULL && s->filename != (char *) NULL) { - register FILE *stream; - register int i, desc, c, line_width, nlines; - register char *src_line = 0; + FILE *stream; + int i, desc, c, line_width, nlines; + char *src_line = 0; if ((ret = tui_alloc_source_buffer (TUI_SRC_WIN)) == TUI_SUCCESS) { @@ -92,7 +92,7 @@ tui_set_source_content (struct symtab *s, int line_no, int noerror) } else { - register int offset, cur_line_no, cur_line, cur_len, threshold; + int offset, cur_line_no, cur_line, cur_len, threshold; struct tui_gen_win_info * locator = tui_locator_win_info_ptr (); struct tui_source_info * src = &TUI_SRC_WIN->detail.source_info; diff --git a/gdb/tui/tui-stack.c b/gdb/tui/tui-stack.c index 601e2fd3355..7285dab9140 100644 --- a/gdb/tui/tui-stack.c +++ b/gdb/tui/tui-stack.c @@ -326,11 +326,11 @@ void tui_show_frame_info (struct frame_info *fi) { struct tui_win_info * win_info; - register int i; + int i; if (fi) { - register int start_line, i; + int start_line, i; CORE_ADDR low; struct tui_gen_win_info * locator = tui_locator_win_info_ptr (); int source_already_displayed; diff --git a/gdb/tui/tui-win.c b/gdb/tui/tui-win.c index f9cb6c0a3fd..3950a7ca4ce 100644 --- a/gdb/tui/tui-win.c +++ b/gdb/tui/tui-win.c @@ -54,7 +54,7 @@ #endif #endif -#include <string.h> +#include "gdb_string.h" #include <ctype.h> #include <readline/readline.h> @@ -241,7 +241,7 @@ translate (const char *name, struct tui_translate *table) Returns 1 if the configuration has changed and the screen should be redrawn. */ int -tui_update_variables () +tui_update_variables (void) { int need_redraw = 0; struct tui_translate *entry; @@ -404,7 +404,7 @@ Usage: w <#lines>\n"); /* Update gdb's knowledge of the terminal size. */ void -tui_update_gdb_sizes () +tui_update_gdb_sizes (void) { char cmd[50]; int screenheight, screenwidth; diff --git a/gdb/tui/tui-winsource.c b/gdb/tui/tui-winsource.c index 7074dcdecbf..6b77c4010ce 100644 --- a/gdb/tui/tui-winsource.c +++ b/gdb/tui/tui-winsource.c @@ -205,7 +205,7 @@ tui_clear_source_content (struct tui_win_info * win_info, int display_prompt) { if (win_info != NULL) { - register int i; + int i; win_info->generic.content_in_use = FALSE; tui_erase_source_content (win_info, display_prompt); @@ -372,7 +372,7 @@ tui_set_is_exec_point_at (union tui_line_or_address l, struct tui_win_info * win This is called whenever a breakpoint is inserted, removed or has its state changed. */ void -tui_update_all_breakpoint_info () +tui_update_all_breakpoint_info (void) { struct tui_list *list = tui_source_windows (); int i; @@ -558,8 +558,8 @@ tui_update_exec_info (struct tui_win_info * win_info) enum tui_status tui_alloc_source_buffer (struct tui_win_info *win_info) { - register char *src_line_buf; - register int i, line_width, max_lines; + char *src_line_buf; + int i, line_width, max_lines; enum tui_status ret = TUI_FAILURE; max_lines = win_info->generic.height; /* less the highlight box */ diff --git a/gdb/tui/tui.c b/gdb/tui/tui.c index a29cf11ad7f..c05c8f93246 100644 --- a/gdb/tui/tui.c +++ b/gdb/tui/tui.c @@ -283,7 +283,7 @@ tui_rl_next_keymap (int notused1, int notused2) the command window is cleaner. It will be displayed if we temporarily leave the SingleKey mode. */ static int -tui_rl_startup_hook () +tui_rl_startup_hook (void) { rl_already_prompted = 1; if (tui_current_key_mode != TUI_COMMAND_MODE) @@ -305,7 +305,7 @@ tui_set_key_mode (enum tui_key_mode mode) /* Initialize readline and configure the keymap for the switching key shortcut. */ void -tui_initialize_readline () +tui_initialize_readline (void) { int i; Keymap tui_ctlx_keymap; |