Skip to content

Commit e587bb5

Browse files
committed
Use allocate instead of allocateDirect in MultiBuffer constructor
1 parent e8c6cfb commit e587bb5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/com/maxmind/db/MultiBuffer.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,10 +96,10 @@ public MultiBuffer(long capacity) {
9696
this.buffers = new ByteBuffer[totalChunks];
9797

9898
for (int i = 0; i < fullChunks; i++) {
99-
buffers[i] = ByteBuffer.allocateDirect(chunkSize);
99+
buffers[i] = ByteBuffer.allocate(chunkSize);
100100
}
101101
if (remainder > 0) {
102-
buffers[totalChunks - 1] = ByteBuffer.allocateDirect(remainder);
102+
buffers[totalChunks - 1] = ByteBuffer.allocate(remainder);
103103
}
104104
}
105105

0 commit comments

Comments
 (0)