From: Guillaume Marcais Date: 2006-01-24T14:33:53+09:00 Subject: Buffered IO and UDPSocket This one is driving me nuts! What causes and IO object (more specifically a UDPSocket here, bound to port 1025) to become "buffered"? When I do simple test case in irb with such a socket, I can call #recvfrom on it with no problem. In my actual server, I get the error: "`recvfrom': recv for buffered IO (IOError)". I can't figure out why. I payed attention that no threads are created, I do a select on this socket (and others) to check for read readiness before calling #recvfrom. So what made the socket suddenly buffered so that #recv becomes illegal? How can I check the buffered status of an IO? Can I revert it from buffered to unbuffered? It seems that I could get around this condition with #readpartial. But this method is not avaible in 1.8.2. This code will need to run on Windows and I rely on the one click installer... Could someone shed some light on this "buffered" issue? It confuses the hell out of me and the Google responses didn't enlighten me. Guillaume.