[Python-checkins] r65581 - python/trunk/Modules/fcntlmodule.c
guido.van.rossum
python-checkins at python.org
Thu Aug 7 20:51:38 CEST 2008
Author: guido.van.rossum
Date: Thu Aug 7 20:51:38 2008
New Revision: 65581
Log:
Patch by Ian Charnas from issue 3517.
Add F_FULLFSYNC if it exists (OS X only so far).
Modified:
python/trunk/Modules/fcntlmodule.c
Modified: python/trunk/Modules/fcntlmodule.c
==============================================================================
--- python/trunk/Modules/fcntlmodule.c (original)
+++ python/trunk/Modules/fcntlmodule.c Thu Aug 7 20:51:38 2008
@@ -530,6 +530,11 @@
if (ins(d, "F_SHLCK", (long)F_SHLCK)) return -1;
#endif
+/* OS X (and maybe others) let you tell the storage device to flush to physical media */
+#ifdef F_FULLFSYNC
+ if (ins(d, "F_FULLFSYNC", (long)F_FULLFSYNC)) return -1;
+#endif
+
/* For F_{GET|SET}FL */
#ifdef FD_CLOEXEC
if (ins(d, "FD_CLOEXEC", (long)FD_CLOEXEC)) return -1;
More information about the Python-checkins
mailing list