From: Martin v. Löwis Date: Fri, 31 Oct 2003 13:01:24 +0000 (+0000) Subject: Patch #787189: Explicitly define CTRL on SGI. X-Git-Tag: v2.4a1~1342 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=be4fea6198013c808d702210b065394d0771fd28;p=python Patch #787189: Explicitly define CTRL on SGI. --- diff --git a/Modules/termios.c b/Modules/termios.c index 7e4eb7ba8d..a1d14a18b8 100644 --- a/Modules/termios.c +++ b/Modules/termios.c @@ -4,6 +4,12 @@ #define PyInit_termios inittermios +/* Apparently, on SGI, termios.h won't define CTRL if _XOPEN_SOURCE + is defined, so we define it here. */ +#if defined(__sgi) +#define CTRL(c) ((c)&037) +#endif + #include #ifdef __osf__ /* On OSF, sys/ioctl.h requires that struct termio already be defined,