[PATCH] LWP::UserAgent add support for URI with embedded userinfo

"Philippe Bruhat (BooK)" <[email protected]>
Newsgroups gmane.comp.lang.perl.modules.lwp
Message-ID <[email protected]>
Signed-off-by: Philippe Bruhat (BooK) <[email protected]>
---
 lib/LWP/UserAgent.pm |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/lib/LWP/UserAgent.pm b/lib/LWP/UserAgent.pm
index a54782c..7757126 100644
--- a/lib/LWP/UserAgent.pm
+++ b/lib/LWP/UserAgent.pm
@@ -572,6 +572,7 @@ sub get_basic_credentials
 {
     my($self, $realm, $uri, $proxy) = @_;
     return if $proxy;
+    return $uri->userinfo if $uri->can('userinfo') && $uri->userinfo;
     return $self->credentials($uri->host_port, $realm);
 }
 
-- 
1.6.0.3.517.g759a
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.