Fix search in TUI
authorHannes Domani <ssbssa@yahoo.de>
Sun, 22 Dec 2019 13:58:22 +0000 (14:58 +0100)
committerHannes Domani <ssbssa@yahoo.de>
Mon, 6 Jan 2020 16:14:13 +0000 (17:14 +0100)
The variable last_line_listed is never set when print_source_lines_base is
called in TUI mode, so the search always started from the last line printed
outside of TUI mode.

gdb/ChangeLog:

2020-01-06  Hannes Domani  <ssbssa@yahoo.de>

* source.c (print_source_lines_base): Set last_line_listed.

gdb/ChangeLog
gdb/source.c

index 8101a6f54afff21f484960c23c442d10d818f369..ad7c33fe46510ddf85c1b498e05bcf52427d4fb8 100644 (file)
@@ -1,3 +1,7 @@
+2020-01-06  Hannes Domani  <ssbssa@yahoo.de>
+
+       * source.c (print_source_lines_base): Set last_line_listed.
+
 2020-01-06  Shahab Vahedi  <shahab@synopsys.com>
 
        * tui/tui-disasm.c: Remove trailing spaces.
index 7230c77f7333530803606de71e924f79fc870401..1bc98d376e55ce67b5d78c88b39b1960d16cbf2a 100644 (file)
@@ -1232,6 +1232,7 @@ print_source_lines_base (struct symtab *s, int line, int stopline,
 
   loc->set (s, line);
   first_line_listed = line;
+  last_line_listed = line;
 
   /* If printing of source lines is disabled, just print file and line
      number.  */
This page took 0.025285 seconds and 4 git commands to generate.