mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-15 10:30:25 -08:00
Trivial unrmail fix for empty input files.
* lisp/mail/unrmail.el (unrmail): Give an explicit error if the input file has no messages. Fixes: debbugs:10377
This commit is contained in:
parent
c869783d91
commit
665ae8654b
2 changed files with 5 additions and 1 deletions
|
|
@ -66,7 +66,8 @@ For example, invoke `emacs -batch -f batch-unrmail RMAIL'."
|
|||
from to)
|
||||
(goto-char (point-min))
|
||||
(search-forward "\n\^_" nil t) ; Skip BABYL header.
|
||||
(setq from (point))
|
||||
(if (= (setq from (point)) (point-max))
|
||||
(error "The input file contains no messages"))
|
||||
(goto-char (point-max))
|
||||
(search-backward "\n\^_" from 'mv)
|
||||
(setq to (point))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue