emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Bug: Can't follow link to old Gnus nndoc article [6.34trans]
@ 2010-03-08  5:32 Thomas Morgan
  0 siblings, 0 replies; only message in thread
From: Thomas Morgan @ 2010-03-08  5:32 UTC (permalink / raw)
  To: emacs-orgmode

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

I'm using development versions of Emacs and Org mode:

  Emacs  : GNU Emacs 23.1.90.1 (i686-pc-linux-gnu, GTK+ Version 2.18.3)
   of 2010-03-03 on enif
  Package: Org-mode version 6.34trans

When I try to follow (with `C-c C-o') a link to an already
read article in a Gnus nndoc group, I get an error message
like this:

  Couldn't fetch article <000001cabb88$b67f8fc0$237eaf40$@email.ne.jp>

Here is the link location for that message:

  gnus:nndoc+/home/tlm/Mail/RMAIL-201003:RMAIL-201003#000001cabb88$b67f8fc0$237eaf40$@email.ne.jp

I'm able to follow the link if the group is already open
with all old articles visible.

I've attached a patch which is probably not a proper fix.
It solves the problem by making `org-gnus-follow-link'
read the entire group from the start instead of beginning
with one article and trying more if the group fails to open.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Make-org-gnus-follow-link-immediately-read-all-artic.patch --]
[-- Type: text/x-diff, Size: 1449 bytes --]

From 271f6880df3227764b090e5ad9b1c6ab16deee76 Mon Sep 17 00:00:00 2001
From: Thomas Morgan <tlm@ziiuu.com>
Date: Sun, 7 Mar 2010 20:43:41 -0800
Subject: [PATCH] Make `org-gnus-follow-link' immediately read all articles in group
 instead of starting with 1.

---
 lisp/org-gnus.el |   17 ++++-------------
 1 files changed, 4 insertions(+), 13 deletions(-)

diff --git a/lisp/org-gnus.el b/lisp/org-gnus.el
index dd357b7..370e535 100644
--- a/lisp/org-gnus.el
+++ b/lisp/org-gnus.el
@@ -169,19 +169,10 @@ If `org-store-link' was called with a prefix arg the meaning of
   (cond ((and group article)
 	 (gnus-activate-group group t)
 	 (condition-case nil
-	     (let ((articles 1)
-		   group-opened)
-	       (while (and (not group-opened)
-			   ;; stop on integer overflows
-			   (> articles 0))
-		 (setq group-opened (gnus-group-read-group articles nil group)
-		       articles (if (< articles 16)
-				    (1+ articles)
-				  (* articles 2))))
-	       (if group-opened
-		   (gnus-summary-goto-article article nil t)
-		 (message "Couldn't follow gnus link.  %s"
-			  "The summary couldn't be opened.")))
+	     (if (gnus-group-read-group t nil group)
+		 (gnus-summary-goto-article article nil t)
+	       (message "Couldn't follow gnus link.  %s"
+			"The summary couldn't be opened."))
 	   (quit (message "Couldn't follow gnus link.  %s"
 			  "The linked group is empty."))))
 	(group (gnus-group-jump-to-group group))))
-- 
1.6.3.3


[-- Attachment #3: Type: text/plain, Size: 201 bytes --]

_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2010-03-08  5:32 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-03-08  5:32 Bug: Can't follow link to old Gnus nndoc article [6.34trans] Thomas Morgan

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).