length -= actual;
if (length == 0) { // complete, can leave
return;
}
// otherwise, need another segment, so complete current write
seg.finishWriting();
// and allocate, init-for-writing new one:
BytesSegment newSeg = _reuseFree().initForWriting();
seg.relink(newSeg);
_head = seg = newSeg;
}