Moved the functions to get/set non-blocking state to IO.STREAMS .