PATCH: kdebase/kioslave/man/man2html.cpp

Thiago Macieira thiago at kde.org
Thu Jan 7 18:15:36 GMT 2010


Em Quinta-feira 7. Janeiro 2010, às 17.39.35, Dawit A. escreveu:
> >
> > The difference is of whether the path is relative or not. If you're on
> > info:/libc/bar.html and you get a link to man:foo.html, the resolution
> > will cause it to become man:/libc/foo.html.
> 
> Right. This is exactly the issue in QtWebKit or is it QUrl ?? 

QUrl.

> Anyway, it
> treats "man:blah" as a relative url when resolving it against a base url
> "man:/path/document" when it should not. That simply contradicts what
>  section 3.1 of RFC 2396 states and I quote:
> 
> "Relative URI references are distinguished from absolute URI in that
> they do not begin with a scheme name."

Yep. It's intentional, but I don't know why:

QUrl QUrl::resolved(const QUrl &relative) const
{
    setup

    // be non strict and allow scheme in relative url
    if (!relative.d->scheme.isEmpty() && relative.d->scheme != d->scheme) {
        t = relative;
    } else {
        the relative path calculation here
    }
    some more work

    return t;
}

-- 
Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org
  Senior Product Manager - Nokia, Qt Development Frameworks
      PGP/GPG: 0x6EF45358; fingerprint:
      E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20100107/dba0bca1/attachment.sig>


More information about the kde-core-devel mailing list