fix fatal error in buffered write
do not try to write data of a socket that is waiting for its write complete callback to be called
update the internal time after calling select(2)