Subject: Re: bug#10257: 23.3.1 Cygwin: network drives - file is write protected (false positive)

From: jari <[email-masked]>
Date: Tue, 13 Dec 2011 20:05:47 +0200

On 2011-12-13 19:48, Eli Zaretskii wrote:
| > Date: Tue, 13 Dec 2011 18:26:28 +0200
| > From: jari <[email-masked]>
| > Cc: [email-masked], [email-masked]
| > 
| >      - The mapped drive can be written to without any extra 1:1 GUID,UID
| >        configuration.
| >      - Under Cygwin, should Emacs rely on unreliable[*] UID, GID?
| >      - Is there need for this extra prompt? The protective
| >        nature turned into nightmare.
| > 
| > Much better would be to give control back to the user:
| > 
| >   (setq write-file-interactive-confirmation-flag nil)
| > 
| > This doesn't affect Emacs's ability to signal an error on write
| > failure.
| 
| Emacs assumes Posix-compliant APIs wrt UID/GID/EUID.  Platforms that
| don't comply with the Posix semantics of these APIs should either
| (a) become more compliant, or (b) modify the Emacs sources with
| platform-specific code or #ifdef's to work around the lack of
| compliance.  (Emacs maintainers generally prefer the former
| possibility, for obvious reasons.)  All the other platforms do one
| or the other; why should Cygwin be different? why should we change
| long-standing Emacs code because one platform turns out to be non-
| compliant, and the user refuses to work around the problem by
| configuring his system in a slightly different way?

The proposed chnage, by letting the use to control the
prompting/checking behavior, would solve the issue.

As far as I can tell, it wouldn't break anything.

User already has a write access to the device.

Emacs just doesn't know / guesses wrong / environment is complex /
possibly uses wrong methodology (see Ken's notes about using uid, gid
for write access check).

So why not let user to help it to know via variable?

Jari