From 116fc88311bff52a42a84721c14fc8a4a31682bb Mon Sep 17 00:00:00 2001 From: Andrea Cavalli Date: Wed, 20 Apr 2022 23:29:39 +0200 Subject: [PATCH] Bugfix --- .../dbengine/database/disk/LLLocalKeyValueDatabase.java | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/main/java/it/cavallium/dbengine/database/disk/LLLocalKeyValueDatabase.java b/src/main/java/it/cavallium/dbengine/database/disk/LLLocalKeyValueDatabase.java index 91d2932..ea936b9 100644 --- a/src/main/java/it/cavallium/dbengine/database/disk/LLLocalKeyValueDatabase.java +++ b/src/main/java/it/cavallium/dbengine/database/disk/LLLocalKeyValueDatabase.java @@ -572,7 +572,7 @@ public class LLLocalKeyValueDatabase implements LLKeyValueDatabase { } snapshotsHandles.forEach((id, snapshot) -> { try { - if (db.isOwningHandle() && snapshot.isOwningHandle()) { + if (db.isOwningHandle()) { db.releaseSnapshot(snapshot); } } catch (Exception ex2) { @@ -1058,9 +1058,6 @@ public class LLLocalKeyValueDatabase implements LLKeyValueDatabase { if (!db.isOwningHandle()) { return null; } - if (!dbSnapshot.isOwningHandle()) { - return null; - } db.releaseSnapshot(dbSnapshot); return null; } finally {