Skip to contentSkip to conversation

Substitute O_DSYNC with O_FSYNC as needed.

PATCH In review G 3 2 participants 2 messages Jul 13, 2009 1 message not in the archive Block layer

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

G 3

author
#1 lore raw

PATCH 1/1 Substitute O_DSYNC with O_FSYNC as needed.

This will allow raw-posix.c to compile on systems that don't have O_SYNC defined.

---
 block/raw-posix.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)
block/raw-posix.c +5 -0
index 8b1e67c..d542591 100644
@@ -81,8 +81,13 @@
 
 /* OS X does not have O_DSYNC */
 #ifndef O_DSYNC
+#ifdef O_SYNC
 #define O_DSYNC O_SYNC
+#elif defined(O_FSYNC)
+#define O_DSYNC O_FSYNC
 #endif
+#endif
+
 
 /* Approximate O_DIRECT with O_DSYNC if O_DIRECT isn't available */
 #ifndef O_DIRECT
Signature · 1 line
1.6.3.3
#2 lore raw
Quoted 3 lines · G 3 wrote:

This will allow raw-posix.c to compile on systems that don't have O_SYNC defined.

This is already committed as 1c27a8b35ed2736a0542983facbe861d44785a44

Regards,

Anthony Liguori