Iterator<? extends IoFuture> i = futures.iterator();
while (i.hasNext()) {
IoFuture f = i.next();
do {
if (interruptable) {
lastComplete = f.await(waitTime);
} else {
lastComplete = f.awaitUninterruptibly(waitTime);
}
waitTime = timeoutMillis - (System.currentTimeMillis() - startTime);