From: Reiner Steib <reinersteib+gmane@imap.cc>
Subject: gnus-group-catchup-current-all fails: gnus-sequence-of-unread-articles
Date: Mon, 27 Feb 2006 19:51:49 +0100 [thread overview]
Message-ID: <v9lkvwfxdm.fsf@marauder.physik.uni-ulm.de> (raw)
Hi,
in my Gnus test environment I tried to catchup all groups. It failed
on the following group which doesn't exist anymore on the server
(local group in leafnode):
,----[ `G E' ]
| ;;; Editing the group info for `local.newsletters.test'.
| ;; Type `C-c C-c' after you've finished editing.
|
| ("local.newsletters.test" 6
| ((1 . 292))
| nil)
`----
,----[ Debugger output with patch[1] ]
| Debugger entered--Lisp error: (wrong-type-argument number-or-marker-p nil)
| <(293 nil)
| (cond ((< first last) (push ... unread)) ((= first last) (push first unread)))
| (let* ((read ...) (active ...) (last ...) first nlast unread)
| (gnus-message 1 "RS: group=%s\nRS: read=%s active=%s last=%s"
| group read active last) (if (not read) (setq first ...) (if
| ... ... ... ...)) (gnus-message 1 "RS: first=%s last=%s" first last)
| (cond (... ...) (... ...)) (delq 0 (nreverse unread)))
| gnus-sequence-of-unread-articles("local.newsletters.test")
| gnus-group-catchup("local.newsletters.test" all)
| gnus-group-catchup-current(nil all)
| gnus-group-catchup-current-all(nil)
| call-interactively(gnus-group-catchup-current-all)
`----
The problem is that the code in `gnus-sequence-of-unread-articles'
doesn't ensure that `first' and `last' are both numbers:
,----[ M-: (gnus-sequence-of-unread-articles "local.test") RET with [1] ]
| gnus-sequence-of-unread-articles
| RS: group=local.newsletters.test
| RS: read=((1 . 292)) active=nil last=nil
| RS: first=293 last=nil
| Entering debugger...
`----
What value should `gnus-sequence-of-unread-articles' return in such a
situation?
*time passes*
After a little testing, I conclude that it should return `nil'. Fixed
in CVS.
Bye, Reiner.
[1]
--8<---------------cut here---------------start------------->8---
--- gnus-sum.el 23 Feb 2006 20:30:28 -0000 7.117
+++ gnus-sum.el 27 Feb 2006 18:05:11 -0000
@@ -6626,6 +6626,8 @@
(active (or (gnus-active group) (gnus-activate-group group)))
(last (cdr active))
first nlast unread)
+ (gnus-message 1 "RS: group=%s\nRS: read=%s active=%s last=%s"
+ group read active last)
;; If none are read, then all are unread.
(if (not read)
(setq first (car active))
@@ -6648,6 +6650,8 @@
(setq first (1+ (if (atom (car read)) (car read) (cdar read))))
(setq nlast (if (atom (cadr read)) (cadr read) (caadr read)))
(setq read (cdr read)))))
+ ;; FIXME: Make sure that first and last are integers (non-nil).
+ (gnus-message 1 "RS: first=%s last=%s" first last)
;; And add the last unread articles.
(cond ((< first last)
(push (cons first last) unread))
--8<---------------cut here---------------end--------------->8---
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
reply other threads:[~2006-02-27 18:51 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=v9lkvwfxdm.fsf@marauder.physik.uni-ulm.de \
--to=reinersteib+gmane@imap.cc \
--cc=Reiner.Steib@gmx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).