X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FMailer%2FSendmail.pm;h=3a6c2c6ca84201db1b3bea7f3aaf264c459062b4;hb=5ea712a250510e49b93e8cc82b7426229bb890b6;hp=6b24ecdb5f134211fd52c5af65256399bfd13c67;hpb=6f92326a8f2c1f9205a062d32ed8f1abdaa4b7b5;p=kivitendo-erp.git diff --git a/SL/Mailer/Sendmail.pm b/SL/Mailer/Sendmail.pm index 6b24ecdb5..3a6c2c6ca 100644 --- a/SL/Mailer/Sendmail.pm +++ b/SL/Mailer/Sendmail.pm @@ -2,6 +2,7 @@ package SL::Mailer::Sendmail; use strict; +use Encode; use IO::File; use SL::Template; @@ -17,7 +18,7 @@ sub init { Rose::Object::init(@_); - my $email = $self->mailer->recode($self->myconfig->{email}); + my $email = Encode::encode('utf-8', $self->myconfig->{email}); $email =~ s/[^\w\.\-\+=@]//ig; my %temp_form = ( %{ $self->form }, myconfig_email => $email ); @@ -26,6 +27,7 @@ sub init { $sendmail = $template->parse_block($sendmail); $self->{sendmail} = IO::File->new("|$sendmail") || die "sendmail($sendmail): $!"; + $self->{sendmail}->binmode(':utf8'); } sub start_mail {