Update removeDirect

This commit is contained in:
Andrea Cavalli 2022-02-11 12:16:46 +01:00
parent 83b1d29047
commit 5ebc9abe43

View File

@ -172,12 +172,7 @@ public class CappedWriteBatch extends WriteBatch {
ByteBuffer keyNioBuffer; ByteBuffer keyNioBuffer;
if (USE_FAST_DIRECT_BUFFERS && (keyNioBuffer = asReadOnlyDirect(key)) != null) { if (USE_FAST_DIRECT_BUFFERS && (keyNioBuffer = asReadOnlyDirect(key)) != null) {
buffersToRelease.add(key); buffersToRelease.add(key);
removeDirect(nativeHandle_, remove(columnFamilyHandle, keyNioBuffer);
keyNioBuffer,
keyNioBuffer.position(),
keyNioBuffer.remaining(),
columnFamilyHandle.nativeHandle_
);
} else { } else {
try { try {
super.delete(columnFamilyHandle, LLUtils.toArray(key)); super.delete(columnFamilyHandle, LLUtils.toArray(key));