mdbx-tools: add to mdbx_chk output the number of keys/entries from a pages.

Change-Id: I7c2d779fa89848287f8b5a0fa1ff2fc89c5a9b8c
This commit is contained in:
Leonid Yuriev 2021-03-19 23:20:23 +03:00
parent b71206d119
commit 9e5fe2c61d

View File

@ -366,9 +366,11 @@ static int pgvisitor(const uint64_t pgno, const unsigned pgnumber,
print(" %s-page %" PRIu64, pagetype_caption, pgno); print(" %s-page %" PRIu64, pagetype_caption, pgno);
else else
print(" %s-span %" PRIu64 "[%u]", pagetype_caption, pgno, pgnumber); print(" %s-span %" PRIu64 "[%u]", pagetype_caption, pgno, pgnumber);
print(" of %s: header %" PRIiPTR ", payload %" PRIiPTR print(" of %s: header %" PRIiPTR ", %s %" PRIiPTR ", payload %" PRIiPTR
", unused %" PRIiPTR ", deep %i\n", ", unused %" PRIiPTR ", deep %i\n",
dbi->name, header_bytes, payload_bytes, unused_bytes, deep); dbi->name, header_bytes,
(pagetype == MDBX_page_branch) ? "keys" : "entries", nentries,
payload_bytes, unused_bytes, deep);
} }
bool already_used = false; bool already_used = false;