From 657e62d2223387f5b968e6cfc15f7caef68ade76 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Sat, 31 Mar 2012 15:45:21 +0200 Subject: [PATCH] Fixed the invalid duplicate left over nodes. * Accidently introduced that bug in r43837; the arrayCount variable was not being updated after the value got removed. --- src/add-ons/kernel/file_systems/bfs/BPlusTree.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/add-ons/kernel/file_systems/bfs/BPlusTree.cpp b/src/add-ons/kernel/file_systems/bfs/BPlusTree.cpp index bcd7ddcd08..2397a7b563 100644 --- a/src/add-ons/kernel/file_systems/bfs/BPlusTree.cpp +++ b/src/add-ons/kernel/file_systems/bfs/BPlusTree.cpp @@ -1812,8 +1812,10 @@ BPlusTree::_RemoveDuplicate(Transaction& transaction, return B_BAD_DATA; } - if (array->Remove(value)) + if (array->Remove(value)) { + arrayCount--; break; + } if ((duplicateOffset = duplicate->RightLink()) == BPLUSTREE_NULL) RETURN_ERROR(B_ENTRY_NOT_FOUND);