From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#35624: log-view-diff regression Date: Sat, 11 May 2019 23:58:49 +0300 Organization: LINKOV.NET Message-ID: <875zqgaekq.fsf@mail.linkov.net> References: <87pnou2ak2.fsf@mail.linkov.net> <051f40d7-206b-e5b5-f0b7-2354d0552dcf@yandex.ru> <874l64raeu.fsf@mail.linkov.net> <87imujju04.fsf@mail.linkov.net> <7a87f334-1d60-9d39-959c-97dbad690fc3@yandex.ru> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="200701"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu) Cc: 35624@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat May 11 23:13:22 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1hPZJ3-000q4F-N2 for geb-bug-gnu-emacs@m.gmane.org; Sat, 11 May 2019 23:13:22 +0200 Original-Received: from localhost ([127.0.0.1]:35378 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hPZJ2-0004it-KX for geb-bug-gnu-emacs@m.gmane.org; Sat, 11 May 2019 17:13:20 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:34022) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hPZIr-0004gq-RA for bug-gnu-emacs@gnu.org; Sat, 11 May 2019 17:13:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hPZIq-0004dN-Bn for bug-gnu-emacs@gnu.org; Sat, 11 May 2019 17:13:09 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:56004) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hPZIn-0004ck-RA for bug-gnu-emacs@gnu.org; Sat, 11 May 2019 17:13:06 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1hPZIl-0005oi-BM for bug-gnu-emacs@gnu.org; Sat, 11 May 2019 17:13:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 11 May 2019 21:13:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 35624 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 35624-submit@debbugs.gnu.org id=B35624.155760914722288 (code B ref 35624); Sat, 11 May 2019 21:13:03 +0000 Original-Received: (at 35624) by debbugs.gnu.org; 11 May 2019 21:12:27 +0000 Original-Received: from localhost ([127.0.0.1]:41310 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hPZIB-0005nQ-6V for submit@debbugs.gnu.org; Sat, 11 May 2019 17:12:27 -0400 Original-Received: from common.maple.relay.mailchannels.net ([23.83.214.38]:10060) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hPZI9-0005nI-Ki for 35624@debbugs.gnu.org; Sat, 11 May 2019 17:12:26 -0400 X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id B2B441A13F3; Sat, 11 May 2019 21:12:24 +0000 (UTC) Original-Received: from pdx1-sub0-mail-a85.g.dreamhost.com (100-96-14-60.trex.outbound.svc.cluster.local [100.96.14.60]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 383161A1870; Sat, 11 May 2019 21:12:24 +0000 (UTC) X-Sender-Id: dreamhost|x-authsender|jurta@jurta.org Original-Received: from pdx1-sub0-mail-a85.g.dreamhost.com ([TEMPUNAVAIL]. [64.90.62.162]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384) by 0.0.0.0:2500 (trex/5.17.2); Sat, 11 May 2019 21:12:24 +0000 X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|jurta@jurta.org X-MailChannels-Auth-Id: dreamhost X-Drop-Daffy: 29d203fd4e51c3e5_1557609144533_406489180 X-MC-Loop-Signature: 1557609144532:777340443 X-MC-Ingress-Time: 1557609144532 Original-Received: from pdx1-sub0-mail-a85.g.dreamhost.com (localhost [127.0.0.1]) by pdx1-sub0-mail-a85.g.dreamhost.com (Postfix) with ESMTP id E83938039D; Sat, 11 May 2019 14:12:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=linkov.net; h=from:to:cc :subject:references:date:in-reply-to:message-id:mime-version :content-type; s=linkov.net; bh=aV23FC2Kzf53H+xVO3wQKJ4qp5s=; b= FUUON1tVD/TJ990AKq0rvMGSY9mYDe5dR/aaCOK7r9tN40kGPrbauCUk8+0Fwh8l mLzSK1bcFAlz+E7mqA3ucj8orWz7mUwsIzYV+uflUszk1q2R93k74PRDFFv/KthM fwTqbsaLOHzVC3CxTt6obOqwt8TIi+JTCdqEUT9w2Io= Original-Received: from mail.jurta.org (m91-129-96-230.cust.tele2.ee [91.129.96.230]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: jurta@jurta.org) by pdx1-sub0-mail-a85.g.dreamhost.com (Postfix) with ESMTPSA id 4F84780390; Sat, 11 May 2019 14:12:17 -0700 (PDT) X-DH-BACKEND: pdx1-sub0-mail-a85 In-Reply-To: <7a87f334-1d60-9d39-959c-97dbad690fc3@yandex.ru> (Dmitry Gutov's message of "Fri, 10 May 2019 03:14:34 +0300") X-VR-OUT-STATUS: OK X-VR-OUT-SCORE: -100 X-VR-OUT-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgeduuddrledtgdduieduucetufdoteggodetrfdotffvucfrrhhofhhilhgvmecuggftfghnshhusghstghrihgsvgdpffftgfetoffjqffuvfenuceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujfgurhephffvufhofhffjgfkfgggtgesmhdtreertdertdenucfhrhhomheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqeenucfkphepledurdduvdelrdeliedrvdeftdenucfrrghrrghmpehmohguvgepshhmthhppdhhvghlohepmhgrihhlrdhjuhhrthgrrdhorhhgpdhinhgvthepledurdduvdelrdeliedrvdeftddprhgvthhurhhnqdhprghthheplfhurhhiucfnihhnkhhovhcuoehjuhhriheslhhinhhkohhvrdhnvghtqedpmhgrihhlfhhrohhmpehjuhhriheslhhinhhkohhvrdhnvghtpdhnrhgtphhtthhopegughhuthhovheshigrnhguvgigrdhruhenucevlhhushhtvghrufhiiigvpedt X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:159100 Archived-At: --=-=-= Content-Type: text/plain > I kind of think that the feature the last change added is more valuable > than the regression (especially if the regression is only triggered when > a commit message is expanded). It is triggered not only when a commit message is expanded. Also it is triggered on single-file logs. Admittedly, my previous patch didn't take this into account. Here is a new patch that works also for single-file logs. It relies on the function 'log-view-end-of-defun' that takes care about the "Show 2X entries" footer: --=-=-= Content-Type: text/x-diff Content-Disposition: inline; filename=log-view-diff-end-of-defun.patch diff --git a/lisp/vc/log-view.el b/lisp/vc/log-view.el index e47fad8908..3389264ce6 100644 --- a/lisp/vc/log-view.el +++ b/lisp/vc/log-view.el @@ -618,10 +618,11 @@ log-view-diff-common ;; When TO and FR are the same, or when point is on a line after ;; the last entry, look at the previous revision. (when (or (string-equal fr to) - (>= (point) + (>= end (save-excursion - (goto-char (car fr-entry)) - (forward-line)))) + (goto-char end) + (log-view-end-of-defun) + (point)))) (setq fr (vc-call-backend log-view-vc-backend 'previous-revision nil fr))) (vc-diff-internal t (list log-view-vc-backend --=-=-=--