From 3270e88361efc8ceff21314b489732229f0f98f7 Mon Sep 17 00:00:00 2001 From: "G. Richardson" Date: Mon, 3 Nov 2014 12:52:23 +0100 Subject: [PATCH] Bei Fehler LaTeX Tempfiles als UTF8 einlesen MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Dadurch können Unicode-Zeichen, die in der .tex Datei Fehler verursachen, dem Benutzer an der Oberfläche besser angezeigt werden. --- SL/Form.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/SL/Form.pm b/SL/Form.pm index a61a6c8bb..171b5fff4 100644 --- a/SL/Form.pm +++ b/SL/Form.pm @@ -1137,7 +1137,7 @@ sub parse_template { $full_signature =~ s/\n/
\n/g; $mail->{message} .= $full_signature; - open(IN, "<", $self->{tmpfile}) + open(IN, "<:encoding(UTF-8)", $self->{tmpfile}) or $self->error($self->cleanup . "$self->{tmpfile} : $!"); $mail->{message} .= $_ while ; close(IN); @@ -1326,7 +1326,7 @@ sub cleanup { push @err, $::locale->text('The application "#1" was not found on the system.', $application || 'pdflatex') . ' ' . $::locale->text('Please contact your administrator.'); } elsif (-f "$self->{tmpfile}.err") { - open(FH, "$self->{tmpfile}.err"); + open(FH, "<:encoding(UTF-8)", "$self->{tmpfile}.err"); @err = ; close(FH); } -- 2.20.1