markov2 / perl5-MailTools

Various ancient e-mail related modules
http://perl.overmeer.net/CPAN
1 stars 2 forks source link

[Mail::Header] modify = 1 and trail whitespaces #1

Open targzeta opened 6 years ago

targzeta commented 6 years ago

Hi, when the modify attribute is on, the final whitespaces are deleted. It is the right thing?

use Mail::Header;

my $head = Mail::Header->new();
$head->modify(0);
$head->add(Subject => 'Test   ');

$head->modify(1);
$head->add(Subject => 'Test   ');

print $head->as_string();
$> perl test.pl | cat -E
Subject: Test   $
Subject: Test$

Thank you in advance, Emanuele