On Jun 19 15:27, Ruben Van Boxem wrote:
> 2013/6/19 Corinna Vinschen
> > And there's another problem with this approach.  Unfortunately you can't
> > overwrite symlinks atomically.  You have to remove the old symlink and
> > create a new one.  In the time between removing and recreation, another
> > process could have made a wrong decision based on the non-existence of
> > the symlink.  You could eliminate this problem by deleting and
> > recreating the symlink in an NTFS transaction, but very, very
> > unfortunately Microsoft has announced to drop NTFS transactions from
> > future versions of NTFS(*).
> [...]
> An "alternative" to TxF is doing that in Kernel mode directly of course:
> http://msdn.microsoft.com/en-us/library/windows/hardware/ff565748%28v=vs.85%29.aspx

Cygwin already uses the native NT calls as described in this document.
Many of them are usable from user space without having to create a
kernel driver, see
http://cygwin.com/cgi-bin/cvsweb.cgi/src/winsup/cygwin/syscalls.cc?rev=1.648&content-type=text/x-cvsweb-markup&cvsroot=src
functions start_transaction() and stop_transaction().

However, if future NTFS versions stop supporting transactions, even
using the native NT calls will be useless since the filesystem flags
will have the FILE_SUPPORTS_TRANSACTIONS flag unset (as on ReFS, for
instance).


Corinna

------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to