Charles-François Natali <neolo...@free.fr> added the comment: See also issue 12105. A couple downsides: - O_EXCL is not necessarily portable (doesn't work well with NFS, maybe not on Windows?) - O_EXCL is useful, as is O_CLOEXEC: to be consistent, we should also end up adding all other commonly-used flags, which are really OS-specific
Furthermore, you can achieve the same thing with: os.fdopen(os.open('/etc/fstab', os.O_WRONLY|os.O_CLOEXEC|os.O_CREAT)) it's more verbose, though. ---------- nosy: +neologix _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue12760> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com