[btree] Fix ref-counting on overwritten values

This commit is contained in:
Ming-Hung Tsai
2021-09-09 09:58:45 +08:00
parent f8c40a1fda
commit e7fa012701
5 changed files with 44 additions and 9 deletions

View File

@@ -42,6 +42,16 @@ namespace persistent_data {
uint32_t none_free_before_;
};
inline bool operator==(index_entry const& lhs, index_entry const& rhs) {
// The return value doesn't matter, since the ref-counts of bitmap blocks
// are managed by shadow operations.
return false;
}
inline bool operator!=(index_entry const& lhs, index_entry const& rhs) {
return !(lhs == rhs);
}
struct index_entry_traits {
typedef index_entry_disk disk_type;
typedef index_entry value_type;