Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -441,15 +441,15 @@ public static ClickHouseBitmap deserialize(byte[] bytes, ClickHouseDataType inne
}
// replace the last 5 bytes to flag(boolean for signed/unsigned) and map
// size(integer)
buffer.position(buffer.position() - 5);
((Buffer) buffer).position(buffer.position() - 5);
// always unsigned due to limit of CRoaring
buffer.put((byte) 0);
// big-endian -> little-endian
for (int i = 3; i >= 0; i--) {
buffer.put(bitmaps[i]);
}

buffer.position(buffer.position() - 5);
((Buffer) buffer).position(buffer.position() - 5);
bitmaps = new byte[buffer.remaining()];
buffer.get(bitmaps);
Roaring64NavigableMap b = new Roaring64NavigableMap();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -363,15 +363,15 @@ public static ClickHouseBitmap deserialize(byte[] bytes, ClickHouseDataType inne
}
// replace the last 5 bytes to flag(boolean for signed/unsigned) and map
// size(integer)
buffer.position(buffer.position() - 5);
((Buffer) buffer).position(buffer.position() - 5);
// always unsigned due to limit of CRoaring
buffer.put((byte) 0);
// big-endian -> little-endian
for (int i = 3; i >= 0; i--) {
buffer.put(bitmaps[i]);
}

buffer.position(buffer.position() - 5);
((Buffer) buffer).position(buffer.position() - 5);
bitmaps = new byte[buffer.remaining()];
buffer.get(bitmaps);
Roaring64NavigableMap b = new Roaring64NavigableMap();
Expand Down