X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=SL%2FMailer%2FSendmail.pm;h=3a6c2c6ca84201db1b3bea7f3aaf264c459062b4;hb=19064edf6bd7859e831fdf37cd465f7f933be6f3;hp=c4ab662524e750cc8d96c2c5a70ab0f2bd4273df;hpb=11e0660ffd9f7c92b96fd3d47d190399f03a2a8a;p=kivitendo-erp.git diff --git a/SL/Mailer/Sendmail.pm b/SL/Mailer/Sendmail.pm index c4ab66252..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,7 +27,7 @@ sub init { $sendmail = $template->parse_block($sendmail); $self->{sendmail} = IO::File->new("|$sendmail") || die "sendmail($sendmail): $!"; - $self->{sendmail}->binmode(':utf8') if $::locale->is_utf8; + $self->{sendmail}->binmode(':utf8'); } sub start_mail {