Gnus development mailing list
 help / color / mirror / Atom feed
From: "Bjørn Mork" <bjorn@mork.no>
To: ding@gnus.org
Cc: "Bjørn Mork" <bjorn@mork.no>
Subject: [PATCH 2/2] nnimap.el (nnimap-request-group): group could be empty
Date: Wed,  1 Jul 2015 13:37:56 +0200	[thread overview]
Message-ID: <1435750676-710-3-git-send-email-bjorn@mork.no> (raw)
In-Reply-To: <1435750676-710-1-git-send-email-bjorn@mork.no>

Newly created groups will be empty, with an active list
being nil.  Create a dummy cons list to avoid formatting
bailing out with
 (wrong-type-argument number-or-marker-p nil)

Signed-off-by: Bjørn Mork <bjorn@mork.no>
---
 lisp/nnimap.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lisp/nnimap.el b/lisp/nnimap.el
index ac32c64..aecb6e5 100644
--- a/lisp/nnimap.el
+++ b/lisp/nnimap.el
@@ -815,6 +815,7 @@ textual parts.")
 						t)
 	    (setq active (nth 2 (assoc group nnimap-current-infos)))))
 	(erase-buffer)
+	(or active (setq active (cons 0 0)))
 	(insert (format "211 %d %d %d %S\n"
 			(- (cdr active) (car active))
 			(car active)
-- 
2.1.4




  parent reply	other threads:[~2015-07-01 11:37 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-01 11:37 [PATCH 0/2] two minor fixes for new/empty nnimap group handling Bjørn Mork
2015-07-01 11:37 ` [PATCH 1/2] nnimap.el (nnimap-request-group): don't make nil into a list Bjørn Mork
2015-07-01 11:37 ` Bjørn Mork [this message]
2015-07-01 11:50 ` [PATCH 0/2] two minor fixes for new/empty nnimap group handling Alan Schmitt
2015-07-01 12:23   ` Bjørn Mork
2015-07-01 13:49     ` Alan Schmitt
2015-07-02  2:18 ` Nikolaus Rath
2015-07-06  2:45 ` Eric Abrahamsen
2015-07-06  8:40   ` Bjørn Mork
2015-07-06 15:11     ` Eric Abrahamsen
2015-07-06 15:32 ` Dan Christensen
2015-07-07  2:48   ` Eric Abrahamsen
2015-07-07 23:12     ` Dan Christensen
2015-07-08  4:20       ` Eric Abrahamsen
2015-07-08 21:45         ` Dan Christensen
2015-07-09  1:53           ` Eric Abrahamsen
2015-07-09  2:52             ` Dan Christensen
2015-07-09 13:47               ` Dan Christensen
2015-07-10  2:41                 ` Eric Abrahamsen
2015-07-10 12:42                   ` Dan Christensen
2015-07-12  4:11               ` Eric Abrahamsen
2015-07-12  4:27                 ` Eric Abrahamsen
2015-07-12 17:01                   ` Dan Christensen
2015-07-13  5:36                     ` Eric Abrahamsen
2015-07-08 12:41       ` Eric Abrahamsen

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=1435750676-710-3-git-send-email-bjorn@mork.no \
    --to=bjorn@mork.no \
    --cc=ding@gnus.org \
    /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).