mirror of https://github.com/python/cpython.git
SF bug 595919: popenN return only text mode pipes
popen2() and popen3() created text-mode pipes even when binary mode was asked for. This was specific to Windows.
This commit is contained in:
parent
5403737e3c
commit
7dca21e59f
|
@ -3476,7 +3476,7 @@ _PyPopen(char *cmdstring, int mode, int n)
|
|||
char *m1, *m2;
|
||||
PyObject *p1, *p2;
|
||||
|
||||
if (mode && _O_TEXT) {
|
||||
if (mode & _O_TEXT) {
|
||||
m1 = "r";
|
||||
m2 = "w";
|
||||
} else {
|
||||
|
@ -3508,7 +3508,7 @@ _PyPopen(char *cmdstring, int mode, int n)
|
|||
char *m1, *m2;
|
||||
PyObject *p1, *p2, *p3;
|
||||
|
||||
if (mode && _O_TEXT) {
|
||||
if (mode & _O_TEXT) {
|
||||
m1 = "r";
|
||||
m2 = "w";
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue