for (int i = 0; !consumer.hasNext(); i++) {
if (channel.isSendClosed()) {
setReceiveClosed();
throw new EOFException();
}
sync.await(i, left, TimeUnit.NANOSECONDS);
left = start + unit.toNanos(timeout) - System.nanoTime();
if (left <= 0)
throw new TimeoutException();
}
consumer.poll0();