[unix] Fix deadlock after incoming connection.