use Buffer.remaining()
This commit is contained in:
parent
0d99987eff
commit
f962c371f4
1 changed files with 1 additions and 1 deletions
|
@ -14,7 +14,7 @@ public class SegmentBuilder extends SegmentReader {
|
|||
// the total number of words the buffer can hold
|
||||
private final int capacity() {
|
||||
this.buffer.reset();
|
||||
return (this.buffer.limit() - this.buffer.position()) / 8;
|
||||
return this.buffer.remaining() / 8;
|
||||
}
|
||||
|
||||
// return how many words have already been allocated
|
||||
|
|
Loading…
Reference in a new issue