aboutsummaryrefslogtreecommitdiff
path: root/IkiWiki
diff options
context:
space:
mode:
authorAmitai Schlair <schmonz-web-ikiwiki@schmonz.com>2013-07-27 08:12:01 -0400
committerAmitai Schlair <schmonz-web-ikiwiki@schmonz.com>2013-07-27 08:12:01 -0400
commit462d8f8015db338c7a5c718f1b92006c2bee9cfe (patch)
treec43f8b0919dd4859677be59e73fbee81e7364040 /IkiWiki
parent07cb6368aa2d6404ea24186be816b2d07afec071 (diff)
downloadikiwiki-462d8f8015db338c7a5c718f1b92006c2bee9cfe.tar
ikiwiki-462d8f8015db338c7a5c718f1b92006c2bee9cfe.tar.gz
Honor proxy env vars and reliably honor cookiejar.
Diffstat (limited to 'IkiWiki')
-rw-r--r--IkiWiki/Plugin/aggregate.pm7
-rw-r--r--IkiWiki/Plugin/openid.pm2
-rw-r--r--IkiWiki/Plugin/pinger.pm2
3 files changed, 4 insertions, 7 deletions
diff --git a/IkiWiki/Plugin/aggregate.pm b/IkiWiki/Plugin/aggregate.pm
index be6e8d476..ccbc6c9a9 100644
--- a/IkiWiki/Plugin/aggregate.pm
+++ b/IkiWiki/Plugin/aggregate.pm
@@ -522,11 +522,8 @@ sub aggregate (@) {
}
$feed->{feedurl}=pop @urls;
}
- my $res=URI::Fetch->fetch($feed->{feedurl},
- UserAgent => LWP::UserAgent->new(
- cookie_jar => $config{cookiejar},
- ),
- );
+ my $ua=useragent();
+ my $res=URI::Fetch->fetch($feed->{feedurl}, UserAgent=>$ua);
if (! $res) {
$feed->{message}=URI::Fetch->errstr;
$feed->{error}=1;
diff --git a/IkiWiki/Plugin/openid.pm b/IkiWiki/Plugin/openid.pm
index e3b9982f2..d369e30c9 100644
--- a/IkiWiki/Plugin/openid.pm
+++ b/IkiWiki/Plugin/openid.pm
@@ -241,7 +241,7 @@ sub getobj ($$) {
$ua=LWPx::ParanoidAgent->new;
}
else {
- $ua=LWP::UserAgent->new;
+ $ua=useragent();
}
# Store the secret in the session.
diff --git a/IkiWiki/Plugin/pinger.pm b/IkiWiki/Plugin/pinger.pm
index 588f7a42a..fb0f3ba0a 100644
--- a/IkiWiki/Plugin/pinger.pm
+++ b/IkiWiki/Plugin/pinger.pm
@@ -80,7 +80,7 @@ sub ping {
debug(gettext("LWP not found, not pinging"));
return;
}
- $ua=LWP::UserAgent->new;
+ $ua=useragent();
}
$ua->timeout($config{pinger_timeout} || 15);