This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
Per Bothner writes:
> Andrew Haley wrote:
> > [ An absolute file URL can look like:
> > > > absoluteURI = "file" ":" abs_path
> > abs_path = "/" path_segments
> > > > That is, there is no need for "//".
> > I don't see that in any of the specs.
I got it from RFC 2396. Which I might have read wrongly, of course.
> Technically, "file:/tmp/foo.html" is not a valid URI, as far as I
> can tell. I notice that firefox rewrites it (in the navigation
> bar) to "file:///tmp/foo.html".
>
> Now in practice we may want to allow "file:/tmp/foo.html", but it should > be viewed as an unofficial short-hand for "file:///tmp/foo.html".
> > > And indeed, the URL spec in the
> > SDK docs says 'If the spec's path component begins with a slash
> > character "/" then the path is treated as absolute...' ]
> > The *path* is absolute, but the URI isn't.
> > This matters when resolving a relative URL against a base URI, such as > he URL of the containing document.
> > If we have a base URI "http://bar.com/baz/index.html" and a reference > "/tmp/foo.html" then the resolved URI is "http://bar.com/tmp/foo.html".
> > > But we parse the spec looking for "//" to determine if a URL is
> > absolute,
> > A URL is absolute *only* if it has a "scheme".
I don't really understand what you're suggesting.
Would it be OK to special-case "file" URIs so that "file:/" is rewritten to ""file:///" ?
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |