Select in Python

Dio dio.lee at gmail.com
Tue Jun 27 02:01:22 EDT 2006


#!/usr/bin/env python2

from sys import stdin
from select import select

while 1:
    (rr, wr, er) = select([stdin], [], [])
    for fd in rr:
        print fd

program block in the first select(), after I type something and "enter
", it never block in select() again,why?




More information about the Python-list mailing list