[New-bugs-announce] [issue7346] Redirected stdout fires [Errno 9]

Ecir Hana report at bugs.python.org
Wed Nov 18 18:15:33 CET 2009


New submission from Ecir Hana <ecir.hana at gmail.com>:

I try to log all the output of a program written in Python and C to a
buffer. I create a pipe, redirect stdout to its write-end and then read
its content afterward. However, printing from Python fires "IOError:
[Errno 9] Bad file descriptor". Please see the attached test-case.

It is happening on Windows XP, Python 2.6 and MinGW GCC and I used this
to compile:
gcc -o std.exe std.c -Ic:/dev/include/python2.6 -l python26

PS: It might be that the problem is that Python was compiled with
MSVC2008 and I'm using MinGW but I'm not sure...

----------
components: IO, Windows
files: std.c
messages: 95433
nosy: ecir.hana
severity: normal
status: open
title: Redirected stdout fires [Errno 9]
versions: Python 2.6
Added file: http://bugs.python.org/file15358/std.c

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue7346>
_______________________________________


More information about the New-bugs-announce mailing list