mdbx: добавление UUID для идентификации БД.

This commit is contained in:
Леонид Юрьев (Leonid Yuriev)
2024-07-06 10:46:42 +03:00
parent 319753661a
commit fe31958d46
13 changed files with 246 additions and 72 deletions

View File

@@ -83,7 +83,12 @@ static inline meta_ptr_t meta_tail(const MDBX_env *env,
return r;
}
static inline bool meta_is_used(const troika_t *troika, unsigned n) {
return n == troika->recent || n == troika->prefer_steady;
}
static inline bool meta_bootid_match(const meta_t *meta) {
return memcmp(&meta->bootid, &globals.bootid, 16) == 0 &&
(globals.bootid.x | globals.bootid.y) != 0;
}