On Nov 7, 9:09 am, Lawrence D'Oliveiro <[EMAIL PROTECTED] central.gen.new_zealand> wrote: > In message <[EMAIL PROTECTED]>, Lawrence D'Oliveiro wrote: > > > In message <[EMAIL PROTECTED]>, Thomas > > Christensen wrote: > > >> r = select.select([proc.stdout.fileno()], [], [], 5)[0] > >> if r: > >> # NOTE: This will block since it reads until EOF > >> data = proc.stdout.read() > > > No, it will read what data is available. > > Sorry, maybe not. But you can set O_NOBLOCK on the fd.
Set O_NONBLOCK on proc.fileno() and try using os.read() on that descriptor. -srp -- http://mail.python.org/mailman/listinfo/python-list