From d89c24e82ef83869a38b3615cd580276e34a2f33 Mon Sep 17 00:00:00 2001 From: Jesus Cea Date: Fri, 26 Jan 2018 01:41:43 +0100 Subject: [PATCH] bpo-32660: Solaris should support constants like termios' FIONREAD --- .../next/Library/2018-01-26-01-26-00.bpo-32660.tVJIWV.rst | 2 ++ Modules/termios.c | 6 ++++++ 2 files changed, 8 insertions(+) create mode 100644 Misc/NEWS.d/next/Library/2018-01-26-01-26-00.bpo-32660.tVJIWV.rst diff --git a/Misc/NEWS.d/next/Library/2018-01-26-01-26-00.bpo-32660.tVJIWV.rst b/Misc/NEWS.d/next/Library/2018-01-26-01-26-00.bpo-32660.tVJIWV.rst new file mode 100644 index 000000000000000..5b33e1a19f96286 --- /dev/null +++ b/Misc/NEWS.d/next/Library/2018-01-26-01-26-00.bpo-32660.tVJIWV.rst @@ -0,0 +1,2 @@ +:mod:`termios` makes available ``FIONREAD``, ``FIONCLEX``, ``FIOCLEX``, +``FIOASYNC`` and ``FIONBIO`` also under Solaris/derivatives. diff --git a/Modules/termios.c b/Modules/termios.c index 6ed4395ae4dd4c1..b4aa77f89764a0a 100644 --- a/Modules/termios.c +++ b/Modules/termios.c @@ -8,6 +8,12 @@ #define CTRL(c) ((c)&037) #endif +#if defined(__sun) +/* We could do better. Check issue-32660 */ +#include +#include +#endif + #include #include