diff options
author | Chong Yidong <cyd@stupidchicken.com> | 2009-07-08 03:10:10 +0000 |
---|---|---|
committer | Chong Yidong <cyd@stupidchicken.com> | 2009-07-08 03:10:10 +0000 |
commit | 88d036078bba84460897932ed8686e30f6aa0d21 (patch) | |
tree | 61d0e84cf15973ebf66cf2b94edb05f7794ce87a /lisp/mail/unrmail.el | |
parent | ee047ec4c6f97a20ae8c0eb343e2d359b6992069 (diff) | |
download | emacs-88d036078bba84460897932ed8686e30f6aa0d21.tar.gz |
* mail/unrmail.el (unrmail): Make sure the message ends with two
newlines (Bug#3769).
Diffstat (limited to 'lisp/mail/unrmail.el')
-rw-r--r-- | lisp/mail/unrmail.el | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lisp/mail/unrmail.el b/lisp/mail/unrmail.el index cd71ec58571..e06c41b2c2e 100644 --- a/lisp/mail/unrmail.el +++ b/lisp/mail/unrmail.el @@ -232,6 +232,10 @@ For example, invoke `emacs -batch -f batch-unrmail RMAIL'." (while (search-forward "\nFrom " nil t) (forward-char -5) (insert ?>))) + ;; Make sure the message ends with two newlines + (goto-char (point-max)) + (unless (looking-back "\n\n") + (insert "\n")) ;; Write it to the output file, suitably encoded. (let ((coding-system-for-write coding)) (write-region (point-min) (point-max) to-file t |