On Thu, 18 Jun 2009 15:58:37 +1000, steve wrote: > "Steven D'Aprano" <[email protected]> wrote in > message news:[email protected]... >> On Thu, 18 Jun 2009 10:36:01 +1000, steve wrote: >> >>> 1) Windows does not make a distinction between text and binary files. >> >> Of course it does. ... > Ok, Python makes a distinction between text and binary files.
Microsoft have reported a bug where cmd.exe fails to recognise EOF in a text file: http://support.microsoft.com/kb/156258 The behaviour of reading past the \0x1A character is considered a bug, which says that cmd.exe at least (and by extension Windows apps in general) are expected to stop reading at \0x1A for text files. Technically, the Windows file systems record the length of text files and so an explicit EOF character is redundant, nevertheless, the behaviour of stopping the read at \0x1A is expected. Whether you want to claim it is "Windows" or "the Windows shell" or something else is a fine distinction that makes little difference in practice. Anyway, here's Raymond Chen of Microsoft explaining more: http://blogs.msdn.com/oldnewthing/archive/2004/03/16/90448.aspx -- Steven -- http://mail.python.org/mailman/listinfo/python-list
