chiark / gitweb /
fix noack function: store whole From line contents (not just the email address) in...
[modbot-mtm.git] / stump / bin / processNoack.pl
index 521e36f50e1213c2383adbbef944a17ae223e2e7..ab468d20b77a15cb3977dba6e040e09288abe829 100755 (executable)
@@ -20,9 +20,8 @@ while( <STDIN> ) {
 }
 
 $From =~ s/^From: //;
-if( $From =~ m/([\w-\.]*)\@([\w-\.]+)/ ) {
-  $From = "$1\@$2";
-} else {
+chomp $From;
+if( $From !~ m/([\w-\.]*)\@([\w-\.]+)/ || $From =~ m/\n/) {
   print STDERR "From line `$From' is incorrect\n";
   exit 0;
 }