emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Emacs-diffs] emacs-26 7a8f22b: * test/lisp/url/url-file-tests.el (u


From: Ken Brown
Subject: Re: [Emacs-diffs] emacs-26 7a8f22b: * test/lisp/url/url-file-tests.el (url-file): Use file:///, not file://.
Date: Thu, 27 Jun 2019 23:37:19 +0000
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.7.2

On 6/27/2019 6:30 PM, Juanma Barranquero wrote:
> 
> On Thu, Jun 27, 2019 at 11:57 PM Ken Brown <address@hidden 
> <mailto:address@hidden>> wrote:
> 
>  > This change causes the test to fail on Cygwin.  I think the original 
> "file://"
>  > is the correct prefix.  If concatenated with "/some/file", it yields the 
> URL
>  > "file:///some/file".  Your version with "file:///" as the prefix yields
>  > "file:////some/file", which would refer to a local file "//some/file".
> 
> It's a long-standing issue. The standard says that two slashes are to be 
> followed by a hostname, Three slashes, if there's no hostname.
> 
> So, in fact, Posix apps should strip the initial slash of an absolute 
> pathname 
> before concatenating it to file:///
> 
> https://tools.ietf.org/html/rfc8089
> 
>     Appendix B.  Example URIs
>         The syntax in Section 2 is intended to support file URIs that take
>         the following forms:
>         Local files:
>         o  A traditional file URI for a local file with an empty authority.
>            This is the most common format in use today.  For example:
>            *  "file:///path/to/file"

This is exactly what I said.  From the context, I think it's clear that the 
words "path", "to", and "file" don't contain slashes.

There are four examples in the RFC with four slashes, and in every case it's 
explicitly stated that the URI represents a UNC string.

Ken

reply via email to

[Prev in Thread] Current Thread [Next in Thread]