mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
Fix stale sub-cursor C_INIT flag
Whenever we enter cursor_set() the sub-cursor's flag must be cleared. If the new cursor position has valid subdata it will be initialized again, if not then the sub-cursor has nothing to point to.
This commit is contained in:
parent
8ae56c34d5
commit
56a41d87d4
@ -4856,6 +4856,9 @@ mdb_cursor_set(MDB_cursor *mc, MDB_val *key, MDB_val *data,
|
||||
assert(key);
|
||||
assert(key->mv_size > 0);
|
||||
|
||||
if (mc->mc_db->md_flags & MDB_DUPSORT)
|
||||
mc->mc_xcursor->mx_cursor.mc_flags &= ~(C_INITIALIZED|C_EOF);
|
||||
|
||||
/* See if we're already on the right page */
|
||||
if (mc->mc_flags & C_INITIALIZED) {
|
||||
MDB_val nodekey;
|
||||
|
Loading…
Reference in New Issue
Block a user