From 9923f347c4e4b9ed710de3404444cf46b04135a0 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Sun, 1 Sep 2019 08:13:24 -0600 Subject: Change members of tui_locator_window to std::string This changes two members of tui_locator_window to have type std::string. This removes a static limit. gdb/ChangeLog 2019-09-20 Tom Tromey * tui/tui-stack.h (MAX_LOCATOR_ELEMENT_LEN): Remove define. (struct tui_locator_window) : Now std::string. * tui/tui-stack.c (tui_locator_window::make_status_line) (tui_locator_window::set_locator_fullname) (tui_locator_window::set_locator_info): Update. * tui/tui-source.c (tui_source_window::set_contents) (tui_source_window::showing_source_p): Update. --- gdb/tui/tui-stack.h | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'gdb/tui/tui-stack.h') diff --git a/gdb/tui/tui-stack.h b/gdb/tui/tui-stack.h index b6ffa986a6f..93a79fbd799 100644 --- a/gdb/tui/tui-stack.h +++ b/gdb/tui/tui-stack.h @@ -26,12 +26,6 @@ struct frame_info; -#ifdef PATH_MAX -# define MAX_LOCATOR_ELEMENT_LEN PATH_MAX -#else -# define MAX_LOCATOR_ELEMENT_LEN 1024 -#endif - /* Locator window class. */ struct tui_locator_window : public tui_gen_win_info @@ -57,8 +51,8 @@ struct tui_locator_window : public tui_gen_win_info /* Set the full_name portion of the locator. */ void set_locator_fullname (const char *fullname); - char full_name[MAX_LOCATOR_ELEMENT_LEN]; - char proc_name[MAX_LOCATOR_ELEMENT_LEN]; + std::string full_name; + std::string proc_name; int line_no = 0; CORE_ADDR addr = 0; /* Architecture associated with code at this location. */ -- cgit v1.2.3-65-gdbad