[Date Prev][Date Next] [Chronological] [Thread] [Top]

(ITS#7621) LMDB mdb_stat() bug

Full_Name: Howard Chu
Version: 2.4.32+
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (
Submitted by: hyc

In a0993354a603a970889ad5c160c289ecca316f81 txn_begin() was changed to defer
reading a DB's root node until it was actually referenced, instead of always
reading all DB root nodes at the beginning of a txn. Other ops already handled
this case but mdb_stat() didn't, so if mdb_stat() was called for a named DB in a
fresh txn that hadn't yet referenced any named DBs, it just returned zeroes in
the stat structure. (The mainDB root node is always read so there was no issue

Fixed in bcb67dd22f06a7f7c85350bc548c50ccfc27dbaa