[btree] Fix rebalancing checks

This commit is contained in:
Ming-Hung Tsai 2021-03-25 15:06:52 +08:00
parent e0eb8fea87
commit 8bfe7ee6f3
1 changed files with 1 additions and 1 deletions

View File

@ -338,7 +338,7 @@ namespace persistent_data {
unsigned nr_right = rhs.get_nr_entries();
unsigned max_entries = get_max_entries();
if (nr_left - count > max_entries || nr_right - count > max_entries)
if (nr_left - count > max_entries || nr_right + count > max_entries)
throw runtime_error("too many entries");
if (count > 0) {