[Python-checkins] python/dist/src/Modules main.c,1.68,1.69
sjoerd@users.sourceforge.net
sjoerd@users.sourceforge.net
Fri, 09 Aug 2002 06:35:21 -0700
Update of /cvsroot/python/python/dist/src/Modules
In directory usw-pr-cvs1:/tmp/cvs-serv23408
Modified Files:
main.c
Log Message:
On Cygwin, put stdin, stderr, and stdout in binary mode when the -u
flag is given (to mimic native Windows).
Index: main.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Modules/main.c,v
retrieving revision 1.68
retrieving revision 1.69
diff -C2 -d -r1.68 -r1.69
*** main.c 2 Aug 2002 14:11:23 -0000 1.68
--- main.c 9 Aug 2002 13:35:18 -0000 1.69
***************
*** 5,9 ****
#include "compile.h" /* For CO_FUTURE_DIVISION */
! #ifdef MS_WINDOWS
#include <fcntl.h>
#endif
--- 5,9 ----
#include "compile.h" /* For CO_FUTURE_DIVISION */
! #if defined(MS_WINDOWS) || defined(__CYGWIN__)
#include <fcntl.h>
#endif
***************
*** 305,309 ****
if (unbuffered) {
! #ifdef MS_WINDOWS
_setmode(fileno(stdin), O_BINARY);
_setmode(fileno(stdout), O_BINARY);
--- 305,309 ----
if (unbuffered) {
! #if defined(MS_WINDOWS) || defined(__CYGWIN__)
_setmode(fileno(stdin), O_BINARY);
_setmode(fileno(stdout), O_BINARY);