replace the use of select() for a short sleep with nanosleep().

ok deraadt@ guenther@