From: Graham B. <gb...@us...> - 2003-05-09 16:56:24
|
Update of /cvsroot/perl-ldap/ldap/lib/Net In directory sc8-pr-cvs1:/tmp/cvs-serv25660/lib/Net Modified Files: LDAP.pm Log Message: Fix bug in URL parsing when the host contains a port. Patch from Ziya Suzen Index: LDAP.pm =================================================================== RCS file: /cvsroot/perl-ldap/ldap/lib/Net/LDAP.pm,v retrieving revision 1.49 retrieving revision 1.50 diff -u -d -r1.49 -r1.50 --- LDAP.pm 9 May 2003 12:05:10 -0000 1.49 +++ LDAP.pm 9 May 2003 16:56:21 -0000 1.50 @@ -101,7 +101,7 @@ foreach my $uri (ref($host) ? @$host : ($host)) { my $scheme = $arg->{scheme} || 'ldap'; - (my $h = $uri) =~ s/^(\w+):// and $scheme = $1; + (my $h = $uri) =~ s,^(\w+)://,, and $scheme = $1; my $meth = $obj->can("connect_$scheme") or next; $h =~ s,^//([^/]*).*,$1,; # Extract host $h =~ s/%([A-Fa-f0-9]{2})/chr(hex($1))/eg; # unescape |