Gnus development mailing list
 help / color / mirror / Atom feed
* [patch] gnus-summary-articles-in-thread doesn't work properly with explicit argument
@ 2010-11-24 16:12 Daniel Schoepe
  2010-11-24 20:28 ` Lars Magne Ingebrigtsen
  0 siblings, 1 reply; 2+ messages in thread
From: Daniel Schoepe @ 2010-11-24 16:12 UTC (permalink / raw)
  To: ding

[-- Attachment #1: Type: text/plain, Size: 594 bytes --]


When calling gnus-summary-articles-in-thread with an article that is
different from (gnus-summary-article-number), it can return incorrent
results:

[post]
  [reply1]
    [reply2]
  [reply3]

When calling gnus-summary-articles-in-thread with post's id as argument,
while the point is at [reply2], gnus-summary-go-to-next-thread will jump
to reply3 causing gnus-summary-articles-in-thread to stop searching for
messages right before [reply3].
I think this behaviour is a bug, since it doesn't conform to the
function's documentation.

I attached a patch that should fix this.

Regards,
Daniel


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Patch to fix mentioned issue --]
[-- Type: text/x-patch, Size: 938 bytes --]

From dbcc189b4c9d4c53f7254a1e67040805bd7e4f26 Mon Sep 17 00:00:00 2001
From: Daniel Schoepe <daniel.schoepe@googlemail.com>
Date: Wed, 24 Nov 2010 16:45:26 +0100
Subject: [PATCH] go to correct line in Summary buffer in gnus-summary-articles-in-thread

This fixes a bug that causes gnus-summary-articles-in-thread to return
incorrect results when calling it with an explicit article argument
different from (gnus-summary-article-number)
---
 lisp/gnus-sum.el |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/lisp/gnus-sum.el b/lisp/gnus-sum.el
index ff85d45..4e4fc5b 100644
--- a/lisp/gnus-sum.el
+++ b/lisp/gnus-sum.el
@@ -11232,6 +11232,7 @@ with that article."
 		  (mail-header-subject (gnus-data-header (car data)))))
 		(t nil)))
 	 (end-point (save-excursion
+		      (goto-char (gnus-data-pos (car data)))
 		      (if (gnus-summary-go-to-next-thread)
 			  (point) (point-max))))
 	 articles)
-- 
1.7.2.3


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [patch] gnus-summary-articles-in-thread doesn't work properly with explicit argument
  2010-11-24 16:12 [patch] gnus-summary-articles-in-thread doesn't work properly with explicit argument Daniel Schoepe
@ 2010-11-24 20:28 ` Lars Magne Ingebrigtsen
  0 siblings, 0 replies; 2+ messages in thread
From: Lars Magne Ingebrigtsen @ 2010-11-24 20:28 UTC (permalink / raw)
  To: ding

Daniel Schoepe <daniel.schoepe@googlemail.com> writes:

> I attached a patch that should fix this.

Thanks; applied.

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-11-24 20:28 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-11-24 16:12 [patch] gnus-summary-articles-in-thread doesn't work properly with explicit argument Daniel Schoepe
2010-11-24 20:28 ` Lars Magne Ingebrigtsen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).