[issue8399] Document os.open

2010-04-14 Thread Georg Brandl
Georg Brandl added the comment: I've added a paragraph about O_BINARY in r80080. -- status: open -> closed ___ Python tracker ___ ___

[issue8399] Document os.open

2010-04-14 Thread anatoly techtonik
anatoly techtonik added the comment: On Unix all files are opened in binary mode. On Windows linefeeds are translated to CRLF corrupting files that are meant to be binary. This is the reason of HgGit failure - it uses Dulwich library that creates corrupted Git index file, because on Windows i

[issue8399] Document os.open

2010-04-14 Thread Georg Brandl
Georg Brandl added the comment: Since there is no distinction between text and binary mode on Unix, you shouldn't claim the behavior is not consistent - you get text mode. You need O_BINARY on Windows to get binary mode. O_BINARY is already documented; I've added a better link to it from th

[issue8399] Document os.open

2010-04-14 Thread anatoly techtonik
anatoly techtonik added the comment: s/ can / can't / -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:/

[issue8399] Document os.open

2010-04-14 Thread anatoly techtonik
New submission from anatoly techtonik : Need to document the that os.O_BINARY flag is obligatory for cross-platform behavior of os.open() on Windows. By default os.open() opens file as binary on Unix, but as text on Windows. See also issue2028 for discussion of making os.O_BINARY default on p