On 2006-03-13, Alex Martelli <[EMAIL PROTECTED]> wrote: > Grant Edwards <[EMAIL PROTECTED]> wrote: > ... >> > What does a binary file do that a text file doesn't, aside >> > from not converting the end of line characters? >> >> Nothing. It's the end-of-line conversion that can break binary >> data. > > I believe that a "control-Z" (ord(26)) in a file that's being read as > text, on Windows, is also taken as an end-of-file indication.
Ah yes. IIRC, that's left over from CP/M, where the filesystem didn't keep a file length for files other than a block count. It was up to the application(s) to keep track of where in that last block the "real" data ended. -- Grant Edwards grante Yow! I wonder if I ought at to tell them about my visi.com PREVIOUS LIFE as a COMPLETE STRANGER? -- http://mail.python.org/mailman/listinfo/python-list