Gisle Aas <[EMAIL PROTECTED]> writes:

> > The only change is in the last line, where I've added the abs call
> > with the URL used to make the request. This fixes the problem where a
> > Content-Location: header contains only a filename like 'index.html'. 
> > Then the URL returned will not be fully qualified.
> > 
> > Could this go in to the next LWP release?
> 
> Yes.  I simplified it until it looked like this:
> 
>    sub base
>    {
>        my $self = shift;
>        my $base = $self->header('Content-Base')     ||  # used to be HTTP/1.1
>                   $self->header('Content-Location') ||  # HTTP/1.1
>                   $self->header('Base');                # HTTP/1.0
>        return $HTTP::URI_CLASS->new_abs($base, $self->request->uri);
>    }
> 
> but it will then require URI-1.07 to actually work.

Yes, I tried that first as well, but it didn't work for me, and I
couldn't figure out how the URI_CLASS stuff worked.

Are you going to put this in the next LWP release? Currently this bug
causes most of the bug reports for Checkbot. While I could work around
this in Checkbot, I'd much rather just refer people to a fixed version
of LWP, even if this also means they will need to update URI as well.

Hans

Reply via email to