private void advanceBufferIfNecessary ( ) { ReadableBuffer buffer = buffers . peek ( ) ; if ( buffer . readableBytes ( ) == 0 ) { buffers . remove ( ) . close ( ) ; } }
If the current buffer is exhausted removes and closes it .