From: Pavel Janík Date: Wed, 11 Dec 2002 23:32:41 +0000 (+0000) Subject: Make sure every message ends with a blank line, because some mbox parsers X-Git-Tag: ttn-vms-21-2-B4~12038 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=649fc2c55b24de625125a9eb4adffe6d4748a29f;p=emacs.git Make sure every message ends with a blank line, because some mbox parsers require a blank line before "From " lines. --- diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index b316887fb43..4f0c6a07002 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,8 @@ +2002-12-12 Jonathan Kamens + + * b2m.pl: Make sure every message ends with a blank line, because + some mbox parsers require a blank line before "From " lines. + 2002-12-08 Richard M. Stallman * getopt.c: Do include libintl.h if HAVE_LIBINTL_H. 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;