X-Git-Url: http://www.git.stargrave.org/?a=blobdiff_plain;f=script%2Fpublic-inbox-mda;h=54d0af01414a64c9458a7cf9d3005143bc5f9616;hb=e39585ee2bdcbeaab7b6bd33b3568021042d0879;hp=9da2d90f8f45f0227cf3083a9a726f322be38947;hpb=068c551dada218863a82a99e113f44c64a81b819;p=public-inbox.git diff --git a/script/public-inbox-mda b/script/public-inbox-mda index 9da2d90f..54d0af01 100755 --- a/script/public-inbox-mda +++ b/script/public-inbox-mda @@ -1,5 +1,5 @@ #!/usr/bin/perl -w -# Copyright (C) 2013-2019 all contributors +# Copyright (C) 2013-2020 all contributors # License: AGPL-3.0+ # # Mail delivery agent for public-inbox, run from your MTA upon mail delivery @@ -29,7 +29,7 @@ use PublicInbox::Spamcheck; # in case there's bugs in our code or user error. my $emergency = $ENV{PI_EMERGENCY} || "$ENV{HOME}/.public-inbox/emergency/"; $ems = PublicInbox::Emergency->new($emergency); -my $str = eval { local $/; }; +my $str = do { local $/; }; $str =~ s/\A[\r\n]*From [^\r\n]*\r?\n//s; $ems->prepare(\$str); my $simple = Email::Simple->new(\$str);