pre_read_start_position = bb.position();
marked = true;
}
if( remaining > allowed ) { //read only part of this buffer
bb.limit( bb.position() + allowed ); //limit current buffer
bytes_available += bb.remaining();
shrink_remaining_buffers = true; //shrink any tail buffers
}
else { //full buffer is allowed to be read
bytes_available += remaining;