Skip to content
Browse files

add PERL_LWP_ENV_PROXY env variable to enable env_proxy globally

  • Loading branch information...
1 parent 0a9516a commit 859a3ef8fe4bb2bd5a072db866c7061b9d582fcb @monken monken committed with Oct 6, 2011
Showing with 4 additions and 0 deletions.
  1. +4 −0 lib/LWP/
4 lib/LWP/
@@ -65,6 +65,7 @@ sub new
my $max_redirect = delete $cnf{max_redirect};
$max_redirect = 7 unless defined $max_redirect;
my $env_proxy = delete $cnf{env_proxy};
+ $env_proxy = $ENV{PERL_LWP_ENV_PROXY} unless defined $env_proxy;
my $cookie_jar = delete $cnf{cookie_jar};
my $conn_cache = delete $cnf{conn_cache};
@@ -1432,6 +1433,9 @@ environment variable normally picked up by env_proxy(). Because of
this C<HTTP_PROXY> is not honored for CGI scripts. The
C<CGI_HTTP_PROXY> environment variable can be used instead.
+You can also set the C<PERL_LWP_ENV_PROXY> environment variable to
+enable C<env_proxy> globally.
=head2 Handlers

0 comments on commit 859a3ef

Please sign in to comment.
Something went wrong with that request. Please try again.