Fixed issue #17

This commit is contained in:
Bert Münnich 2012-01-03 19:30:05 +01:00
parent eb9b7a606a
commit d48894fc14

View File

@ -57,7 +57,7 @@ sub paste {
my $str = `$self->{paste_cmd}`; my $str = `$self->{paste_cmd}`;
if ($? == 0) { if ($? == 0) {
$self->tt_paste($self->locale_encode($str)); $self->tt_paste($str);
} else { } else {
print STDERR "error running '$self->{paste_cmd}': $!\n"; print STDERR "error running '$self->{paste_cmd}': $!\n";
} }
@ -71,7 +71,7 @@ sub paste_escaped {
my $str = `$self->{paste_cmd}`; my $str = `$self->{paste_cmd}`;
if ($? == 0) { if ($? == 0) {
$str =~ s/([!#\$%&\*\(\) ='"\\\|\[\]`~,<>\?])/\\\1/g; $str =~ s/([!#\$%&\*\(\) ='"\\\|\[\]`~,<>\?])/\\\1/g;
$self->tt_paste($self->locale_encode($str)); $self->tt_paste($str);
} else { } else {
print STDERR "error running '$self->{paste_cmd}': $!\n"; print STDERR "error running '$self->{paste_cmd}': $!\n";
} }