From 23e1ecbd66e23711d660894402178bac863bad43 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Charles-Fran=C3=A7ois=20Natali?= Date: Wed, 2 Nov 2011 18:58:25 +0100 Subject: [PATCH] Issue #13324: fcntlmodule: Add the F_NOCACHE flag. Patch by Alex Stewart. --- Misc/ACKS | 1 + Modules/fcntlmodule.c | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/Misc/ACKS b/Misc/ACKS index 821a812591..65c402c375 100644 --- a/Misc/ACKS +++ b/Misc/ACKS @@ -919,6 +919,7 @@ Joel Stanley Oliver Steele Greg Stein Chris Stern +Alex Stewart Victor Stinner Richard Stoakley Peter Stoehr diff --git a/Modules/fcntlmodule.c b/Modules/fcntlmodule.c index bfc59855dd..6b7e3fc6e1 100644 --- a/Modules/fcntlmodule.c +++ b/Modules/fcntlmodule.c @@ -540,10 +540,13 @@ all_ins(PyObject* d) 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 */ +/* OS X specifics */ #ifdef F_FULLFSYNC if (ins(d, "F_FULLFSYNC", (long)F_FULLFSYNC)) return -1; #endif +#ifdef F_NOCACHE + if (ins(d, "F_NOCACHE", (long)F_NOCACHE)) return -1; +#endif /* For F_{GET|SET}FL */ #ifdef FD_CLOEXEC -- 2.50.1