Re: win32: emulating select() on pipes

2008-03-18 Thread Bryan Olson
gangesmaster wrote: > i'm trying to figure out if a pipe on win32 has data for me to read. [...] > does anyone know of a better way to tell if data is available on a > pipe? > something that blocks until data is available or the timeout is > elapsed, In Win32 WaitForMultipleObjects and WaitForMul

win32: emulating select() on pipes

2008-03-17 Thread gangesmaster
hi i'm trying to figure out if a pipe on win32 has data for me to read. this is the code i've come up with: def poll(self, timeout, interval = 0.2): """a poor man's version of select() on win32""" from win32pipe import PeekNamedPipe from msvcrt import g