diff options
author | Pavel Janík <Pavel@Janik.cz> | 2002-12-11 23:32:41 +0000 |
---|---|---|
committer | Pavel Janík <Pavel@Janik.cz> | 2002-12-11 23:32:41 +0000 |
commit | 649fc2c55b24de625125a9eb4adffe6d4748a29f (patch) | |
tree | 678cc71ec27a62dd8576b85d374fc0aefd4de83f /lib-src/b2m.pl | |
parent | 590dbcbaa6a2e1a06a589e2ba779c50c5a855e5b (diff) | |
download | emacs-649fc2c55b24de625125a9eb4adffe6d4748a29f.tar.gz emacs-649fc2c55b24de625125a9eb4adffe6d4748a29f.tar.bz2 emacs-649fc2c55b24de625125a9eb4adffe6d4748a29f.zip |
Make sure every message ends with a blank line, because some mbox parsers
require a blank line before "From " lines.
Diffstat (limited to 'lib-src/b2m.pl')
-rw-r--r-- | lib-src/b2m.pl | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib-src/b2m.pl b/lib-src/b2m.pl index 665dfe202d5..40738fd01ed 100644 --- a/lib-src/b2m.pl +++ b/lib-src/b2m.pl @@ -30,7 +30,7 @@ use Mail::Address; use Date::Parse; my($whoami) = basename $0; -my($version) = '$Revision: 1.2 $'; +my($version) = '$Revision: 1.3 $'; my($usage) = "Usage: $whoami [--help] [--version] [--[no]full-headers] [Babyl-file] \tBy default, full headers are printed.\n"; @@ -102,8 +102,9 @@ while (<>) { $full_header = $header; } - # End message with a single newline - s/\s+$/\n/; + # End message with two newlines (some mbox parsers require a blank + # line before the next "From " line). + s/\s+$/\n\n/; # Quote "^From " s/(^|\n)From /$1>From /g; |