How can I know how much to read from a subprocess

Grant Edwards grante at visi.com
Tue Sep 18 18:00:11 CEST 2007


On 2007-09-18, spam.noam at gmail.com <spam.noam at gmail.com> wrote:

> But even if it's fast enough, how do you know how many times you
> should call read(1)? If you do it too much, you'll be blocked until
> more output is available.

You don't know.  That's why you use non-blocking mode.

-- 
Grant Edwards                   grante             Yow! BELA LUGOSI is my
                                  at               co-pilot ...
                               visi.com            



More information about the Python-list mailing list