On Windows, -u implies binary mode for stdin/stdout

(as well as unbuffered stdout/stderr).
This commit is contained in:
Guido van Rossum 1997-01-11 19:28:55 +00:00
parent 919cf1aff1
commit f22d7e2c69
1 changed files with 4 additions and 0 deletions

View File

@ -162,6 +162,10 @@ main(argc, argv)
}
if (unbuffered) {
#ifdef MS_WINDOWS
_setmode(stdin, O_BINARY);
_setmode(stdout, O_BINARY);
#endif
#ifndef MPW
setbuf(stdout, (char *)NULL);
setbuf(stderr, (char *)NULL);