From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 119450 invoked by alias); 22 Dec 2019 14:03:39 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 119442 invoked by uid 89); 22 Dec 2019 14:03:39 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-18.1 required=5.0 tests=AWL,BAYES_00,FREEMAIL_FROM,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.1 spammy=HContent-Transfer-Encoding:8bit X-HELO: sonic305-20.consmr.mail.ir2.yahoo.com Received: from sonic305-20.consmr.mail.ir2.yahoo.com (HELO sonic305-20.consmr.mail.ir2.yahoo.com) (77.238.177.82) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sun, 22 Dec 2019 14:03:38 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.de; s=s2048; t=1577023414; bh=7K2xT81HCI5c6Rvm0pfOr/SY2h9zSD6q+qiFsPOFTT0=; h=From:To:Subject:Date:References:From:Subject; b=lrNzHDfT0qxUcv4Ud9sMFNJeQoZEYQ638ZBIurV5wp6w64hPhPc4Ql5A7huzYBaeVY94Dj34bm7Ivb96WGsud/KDTjNGEBl+fsSIE6j6BTr791PSpHFeFJHqB7nnIyR+xL+PpLxwI1Tz1JN0scJG0ahZqddlC6ys0k3OeYezeAGECCXtcgWjQO7S9J6pXekNGLZqVeSc7s5sfLSL26qMspXalkh6IfND3feO/Y4CQnjtfRz7OMG+ugbBH9n0frwffunhR1XiaZjGJW2qXcCorizapr1s3XtFqFXISzSPrCrK6KZc/FE846OZs60dnmh4b9FwwTewKtUQbuNwDatT1A== Received: from sonic.gate.mail.ne1.yahoo.com by sonic305.consmr.mail.ir2.yahoo.com with HTTP; Sun, 22 Dec 2019 14:03:34 +0000 Received: by smtp412.mail.ir2.yahoo.com (Oath Hermes SMTP Server) with ESMTPA ID 3fe1413622f5ec79ee8d7caa128d24a8; Sun, 22 Dec 2019 14:03:30 +0000 (UTC) From: "Hannes Domani via gdb-patches" Reply-To: Hannes Domani To: gdb-patches@sourceware.org Subject: [PATCH] Fix search in TUI Date: Sun, 22 Dec 2019 14:03:00 -0000 Message-Id: <20191222140316.4044-1-ssbssa@yahoo.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit References: <20191222140316.4044-1-ssbssa.ref@yahoo.de> X-IsSubscribed: yes X-SW-Source: 2019-12/txt/msg00954.txt.bz2 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: 2019-12-22 Hannes Domani * source.c (print_source_lines_base): Set last_line_listed. --- gdb/source.c | 1 + 1 file changed, 1 insertion(+) diff --git a/gdb/source.c b/gdb/source.c index f5cd2a37e4..a6726f14c4 100644 --- a/gdb/source.c +++ b/gdb/source.c @@ -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. */ -- 2.24.1