]> granicus.if.org Git - python/commitdiff
Clarify "b" mode under Unix.
authorGeorg Brandl <georg@python.org>
Sat, 26 Jan 2008 14:02:38 +0000 (14:02 +0000)
committerGeorg Brandl <georg@python.org>
Sat, 26 Jan 2008 14:02:38 +0000 (14:02 +0000)
Doc/tutorial/inputoutput.rst

index d3b912a3de7668524465774cd934eb0b8f606fbf..f9eec9703b55764e7e288754d86cffde258d0836 100644 (file)
@@ -200,7 +200,8 @@ characters in text files are automatically altered slightly when data is read or
 written.  This behind-the-scenes modification to file data is fine for ASCII
 text files, but it'll corrupt binary data like that in :file:`JPEG` or
 :file:`EXE` files.  Be very careful to use binary mode when reading and writing
-such files.
+such files.  On Unix, it doesn't hurt to append a ``'b'`` to the mode, so
+you can use it platform-independently for all binary files.
 
 
 .. _tut-filemethods: