Write \x1a to binary file
Fredrik Lundh
fredrik at pythonware.com
Mon Jul 15 15:10:44 EDT 2002
Martin v. Loewis wrote:
> > I've got a problem with writing "\x1A" to a binary file on Win32 platform.
> > I think due tue an issue wiht popen() this terminates the output stream. Is
> > there any solution for this ?
>
> I think there is some win32 module that allows you to set the default
> open mode for files to "binary".
msvcrt.setmode(filehandle, mode)
see http://www.python.org/doc/current/lib/msvcrt-files.html
for a bit more information.
</F>
More information about the Python-list
mailing list