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

From: Ken Brown <[email-masked]>
Date: Tue, 13 Dec 2011 10:12:46 -0500

I have a question about the emacs side of this.  I wonder what the 
rationale is for testing writability before trying to save the file, and 
then asking the user for confirmation in case the (unreliable) test for 
writability fails (*).

It might be reasonable to just assume that the user really wants to save 
the file; the worst thing that can happen is that the write fails.  Am I 
missing something?

Ken

(*) According to the documentation at

  http://www.kernel.org/doc/man-pages/online/pages/man3/euidaccess.3.html

euidaccess() and access () are not reliable for checking permissions. 
The advice there is to simply try the desired operation and check for 
errors.