mirror of
https://github.com/isar/libmdbx.git
synced 2024-10-29 23:19:20 +08:00
mdbx: backport - ITS#8336 fix page_search_root assert on FreeDB.
Let "illegal" branch pages thru on the FreeDB - the condition is only temporary and will be fixed by the time rebalance finishes. Change-Id: I5d34fd96096f88638db55166aba7194dcef7e429
This commit is contained in:
parent
4fcbaa44f3
commit
3df7c4b1e1
6
mdb.c
6
mdb.c
@ -5410,7 +5410,11 @@ mdb_page_search_root(MDB_cursor *mc, MDB_val *key, int flags)
|
||||
indx_t i;
|
||||
|
||||
mdb_debug("branch page %zu has %u keys", mp->mp_pgno, NUMKEYS(mp));
|
||||
mdb_cassert(mc, NUMKEYS(mp) > 1);
|
||||
/* Don't assert on branch pages in the FreeDB. We can get here
|
||||
* while in the process of rebalancing a FreeDB branch page; we must
|
||||
* let that proceed. ITS#8336
|
||||
*/
|
||||
mdb_cassert(mc, !mc->mc_dbi || NUMKEYS(mp) > 1);
|
||||
mdb_debug("found index 0 to page %zu", NODEPGNO(NODEPTR(mp, 0)));
|
||||
|
||||
if (flags & (MDB_PS_FIRST|MDB_PS_LAST)) {
|
||||
|
Loading…
Reference in New Issue
Block a user