diff options
author | David CARLIER <devnexen@gmail.com> | 2021-12-08 22:28:51 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-08 22:28:51 (GMT) |
commit | 267539bff700c2493778c07eeb1642b9584c4826 (patch) | |
tree | 7a49e35fa40ee5b332c2cd5abaabf0bd4328db1a /Modules | |
parent | 2109f7880b65755329a877da3a7f8a362de07350 (diff) | |
download | cpython-267539bff700c2493778c07eeb1642b9584c4826.zip cpython-267539bff700c2493778c07eeb1642b9584c4826.tar.gz cpython-267539bff700c2493778c07eeb1642b9584c4826.tar.bz2 |
bpo-46016: fcntl module add FreeBSD's F_DUP2FD_CLOEXEC flag support (GH-29993)
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/fcntlmodule.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Modules/fcntlmodule.c b/Modules/fcntlmodule.c index cdf0f9b..ea9b2bc 100644 --- a/Modules/fcntlmodule.c +++ b/Modules/fcntlmodule.c @@ -581,6 +581,14 @@ all_ins(PyObject* m) if (PyModule_AddIntMacro(m, F_NOCACHE)) return -1; #endif +/* FreeBSD specifics */ +#ifdef F_DUP2FD + if (PyModule_AddIntMacro(m, F_DUP2FD)) return -1; +#endif +#ifdef F_DUP2FD_CLOEXEC + if (PyModule_AddIntMacro(m, F_DUP2FD_CLOEXEC)) return -1; +#endif + /* For F_{GET|SET}FL */ #ifdef FD_CLOEXEC if (PyModule_AddIntMacro(m, FD_CLOEXEC)) return -1; |