Skip to content

Commit

Permalink
fixup! groom TableCopyByteStream to use more std
Browse files Browse the repository at this point in the history
  • Loading branch information
faucct committed Oct 29, 2024
1 parent cda2190 commit 1a650a1
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ class TableCopyByteStream(reader: TableReader[ByteBuffer], timeout: Duration,
private def recognizeToken(token: ByteBuffer): Boolean = {
if (hasNext) {
val mismatch = _batch.mismatch(token)
if (mismatch == -1 || mismatch == token.remaining) {
_batch.position(_batch.position + token.remaining)
if (mismatch == -1 || mismatch == token.remaining()) {
_batch.position(_batch.position() + token.remaining())
return true
}
}
Expand Down

0 comments on commit 1a650a1

Please sign in to comment.