Gisle Aas <[EMAIL PROTECTED]> writes: > Still need to figure out why connect fails for me on this test with > perl5.005 ...
With this patch is seems to work fine on perl5.005: Index: lib/Net/HTTP/Methods.pm =================================================================== RCS file: /cvsroot/libwww-perl/lwp5/lib/Net/HTTP/Methods.pm,v retrieving revision 1.3 diff -u -p -u -r1.3 Methods.pm --- lib/Net/HTTP/Methods.pm 2001/11/20 19:48:40 1.3 +++ lib/Net/HTTP/Methods.pm 2001/11/20 20:43:38 @@ -25,13 +25,14 @@ sub http_configure { my $host = delete $cnf->{Host}; my $peer = $cnf->{PeerAddr} || $cnf->{PeerHost}; if ($host) { - $cnf->{PeerHost} = $host unless $peer; + $cnf->{PeerAddr} = $host unless $peer; } else { $host = $peer; $host =~ s/:.*//; } $cnf->{PeerPort} = $self->http_default_port unless $cnf->{PeerPort}; + $cnf->{Proto} = 'tcp'; my $keep_alive = delete $cnf->{KeepAlive}; my $http_version = delete $cnf->{HTTPVersion}; @@ -163,7 +164,7 @@ sub format_request { sub write_request { my $self = shift; - $self->syswrite($self->format_request(@_)); + $self->print($self->format_request(@_)); } sub format_chunk { @@ -175,7 +176,7 @@ sub format_chunk { sub write_chunk { my $self = shift; return 1 unless defined($_[0]) && length($_[0]); - $self->syswrite(hex(length($_[0])) . $CRLF . $_[0] . $CRLF); + $self->print(hex(length($_[0])) . $CRLF . $_[0] . $CRLF); } sub format_chunk_eof { @@ -189,7 +190,7 @@ sub format_chunk_eof { sub write_chunk_eof { my $self = shift; - $self->syswrite($self->format_chunk_eof(@_)); + $self->print($self->format_chunk_eof(@_)); }