]> git.eshelyaron.com Git - emacs.git/commitdiff
* mail/unrmail.el (unrmail): Make sure the message ends with two
authorChong Yidong <cyd@stupidchicken.com>
Wed, 8 Jul 2009 03:10:59 +0000 (03:10 +0000)
committerChong Yidong <cyd@stupidchicken.com>
Wed, 8 Jul 2009 03:10:59 +0000 (03:10 +0000)
newlines (Bug#3769).

lisp/ChangeLog
lisp/mail/unrmail.el

index bca414bbae76a5c3e01e7aefad416c1282b0446e..6cdf1b992e35e4c7c4f3225570c1dbab50a44f8d 100644 (file)
@@ -1,3 +1,8 @@
+2009-07-08  E. Jay Berkenbilt  <ejb@ql.org>  (tiny change)
+
+       * mail/unrmail.el (unrmail): Make sure the message ends with two
+       newlines (Bug#3769).
+
 2009-07-08  Kenichi Handa  <handa@m17n.org>
 
        * language/japanese.el (japanese-shift-jis-2004): Fix typo in the
index cd71ec58571dcb3524c808684f725c35f9da2b06..e06c41b2c2e793bf955d299e4d8e347f1037a473 100644 (file)
@@ -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