WebPaste: restart alarm after pasting with UA::Paranoid

This commit is contained in:
Pragmatic Software 2020-02-04 03:13:44 -08:00
parent 623ed7d317
commit 9d1cdef881
1 changed files with 1 additions and 0 deletions

View File

@ -81,6 +81,7 @@ sub paste_ixio {
push @{ $ua->requests_redirectable }, 'POST';
my %post = ('f:1' => $text);
my $response = $ua->post("http://ix.io", \%post);
alarm 1; # LWP::UserAgent::Paranoid kills alarm
return "error pasting: " . $response->status_line if not $response->is_success;
my $result = $response->content;
$result =~ s/^\s+//;