mirror of
https://github.com/isar/libmdbx.git
synced 2025-01-29 14:08:21 +08:00
mdbx: fix reset of comparison functions on change MainDB flags (backport).
This commit is contained in:
parent
61d19dcf95
commit
0fae7f98da
@ -20327,6 +20327,10 @@ static int mdbx_dbi_bind(MDBX_txn *txn, const MDBX_dbi dbi, unsigned user_flags,
|
||||
/* make sure flags changes get committed */
|
||||
txn->mt_dbs[dbi].md_flags = user_flags & DB_PERSISTENT_FLAGS;
|
||||
txn->mt_flags |= MDBX_TXN_DIRTY;
|
||||
/* обнуляем компараторы для установки в соответствии с флагами,
|
||||
* либо заданных пользователем */
|
||||
txn->mt_dbxs[dbi].md_cmp = nullptr;
|
||||
txn->mt_dbxs[dbi].md_dcmp = nullptr;
|
||||
} else {
|
||||
return /* FIXME: return extended info */ MDBX_INCOMPATIBLE;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user