(rmail-new-summary): Don't try to summarize an empty folder.

This commit is contained in:
Glenn Morris 2009-01-31 03:15:35 +00:00
parent 49e787c9e2
commit ab383a615f
2 changed files with 6 additions and 2 deletions

View file

@ -1,5 +1,8 @@
2009-01-31 Glenn Morris <rgm@gnu.org>
* mail/rmailsum.el (rmail-new-summary): Don't try to summarize an empty
folder.
* mail/rmail.el (rmail-msg-is-pruned): New function.
(rmail-toggle-header): Doc fix. Use rmail-msg-is-pruned.
(rmail-reply): Set up to yank from the decoded message rather than the

View file

@ -204,8 +204,9 @@ nil for FUNCTION means all messages."
(if (eq major-mode 'rmail-summary-mode)
(setq was-in-summary t))
(with-current-buffer rmail-buffer
(setq mesg rmail-current-message
rmail-summary-buffer (rmail-new-summary-1 desc redo func args)))
(if (zerop (setq mesg rmail-current-message))
(error "No messages to summarize"))
(setq rmail-summary-buffer (rmail-new-summary-1 desc redo func args)))
;; Now display the summary buffer and go to the right place in it.
(unless was-in-summary
(if (and (one-window-p)