From: lpsolit%gmail.com <> Date: Wed, 14 May 2008 03:31:22 +0000 (+0000) Subject: Bug 431704: Remove useless newlines in replies sent by email_in.pl - Patch by FrÃ... X-Git-Tag: bugzilla-3.0.5~24 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fb06f3211c59cef476f4dfa6b1512352aabf9750;p=thirdparty%2Fbugzilla.git Bug 431704: Remove useless newlines in replies sent by email_in.pl - Patch by Frédéric Buclin r=mkanat a=LpSolit --- diff --git a/email_in.pl b/email_in.pl index 576aed81ac..29725af63d 100644 --- a/email_in.pl +++ b/email_in.pl @@ -330,6 +330,8 @@ sub html_strip { $var =~ s/\>/>/g; $var =~ s/\"/\"/g; $var =~ s/@/@/g; + # Also remove undesired newlines and consecutive spaces. + $var =~ s/[\n\s]+/ /gms; return $var; } @@ -355,7 +357,7 @@ sub die_handler { my $reply = reply(to => $input_email, top_post => 1, body => "$msg\n"); MessageToMTA($reply->as_string); } - print STDERR $msg; + print STDERR "$msg\n"; # We exit with a successful value, because we don't want the MTA # to *also* send a failure notice. exit;