From: Ken Brown <kbrown@cornell.edu>
To: Eli Zaretskii <eliz@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: master 95b1eacd47: Fix handling of UNCs in 'parse-colon-path
Date: Wed, 24 Aug 2022 18:03:35 -0400 [thread overview]
Message-ID: <72e69a8e-13ba-f36f-d6bd-c4ed4bb0e53e@cornell.edu> (raw)
In-Reply-To: <83v8qh4gw2.fsf@gnu.org>
On 8/24/2022 2:48 PM, Eli Zaretskii wrote:
>> Date: Wed, 24 Aug 2022 14:34:02 -0400
>> From: Ken Brown <kbrown@cornell.edu>
>>
>> On 8/24/2022 12:20 PM, Eli Zaretskii wrote:
>>> branch: master
>>> commit 95b1eacd4750da7329380aabcb383a8f9d96a59b
>>> Author: Eli Zaretskii <eliz@gnu.org>
>>> Commit: Eli Zaretskii <eliz@gnu.org>
>>>
>>> Fix handling of UNCs in 'parse-colon-path
>>>
>>> * lisp/files.el (parse-colon-path): Don't remove the second
>>> leading slash on systems that support UNCs. (Bug#57353)
>>>
>>> * test/lisp/files-tests.el (files-tests-bug-21454): Update
>>> expected results.
>>> (files-colon-path): Add a new test pattern.
>>
>> After this commit I'm getting the following test failure on Cygwin. I don't
>> have time to look into it now, but I can do so in a few days if the fix isn't
>> obvious.
>
> Ugh, it means the test data needs to be split three-way: one for
> MS-Windows/MS-DOS, another for Cygwin, and one more for the rest.
> Because Cygwin is like Posix systems, but it does want to support
> UNCs.
It's not just the test data that's wrong on Cygwin, but parse-colon-path is
wrong: It always collapses multiple leading slashes to two.
Posix says that multiple leading slashes are equivalent to one slash *except* in
the case of exactly two leading slashes. In that case, the interpretation is
implementation-dependent.
Cygwin follows Posix and chooses to interpret precisely two leading slashes as
referring to a UNC path. In particular, 3 or more slashes should be collapsed
to 1 slash, as on other Posix systems, while exactly 2 leading slashes should be
left alone.
Ken
next prev parent reply other threads:[~2022-08-24 22:03 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <166135805961.19216.9573795919733967151@vcs2.savannah.gnu.org>
[not found] ` <20220824162100.7A8DFC0088A@vcs2.savannah.gnu.org>
2022-08-24 18:34 ` master 95b1eacd47: Fix handling of UNCs in 'parse-colon-path Ken Brown
2022-08-24 18:48 ` Eli Zaretskii
2022-08-24 22:03 ` Ken Brown [this message]
2022-08-25 5:18 ` Eli Zaretskii
2022-08-25 12:56 ` Ken Brown
2022-08-27 23:04 ` Ken Brown
2022-08-28 5:16 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=72e69a8e-13ba-f36f-d6bd-c4ed4bb0e53e@cornell.edu \
--to=kbrown@cornell.edu \
--cc=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).