mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-20 22:59:34 -05:00
mdb_cursor_sibling(): Fix error result
This commit is contained in:
parent
8f075595a1
commit
99ea7669a3
1 changed files with 4 additions and 1 deletions
|
|
@ -4942,8 +4942,11 @@ mdb_cursor_sibling(MDB_cursor *mc, int move_right)
|
||||||
assert(IS_BRANCH(mc->mc_pg[mc->mc_top]));
|
assert(IS_BRANCH(mc->mc_pg[mc->mc_top]));
|
||||||
|
|
||||||
indx = NODEPTR(mc->mc_pg[mc->mc_top], mc->mc_ki[mc->mc_top]);
|
indx = NODEPTR(mc->mc_pg[mc->mc_top], mc->mc_ki[mc->mc_top]);
|
||||||
if ((rc = mdb_page_get(mc->mc_txn, NODEPGNO(indx), &mp, NULL) != 0))
|
if ((rc = mdb_page_get(mc->mc_txn, NODEPGNO(indx), &mp, NULL)) != 0) {
|
||||||
|
/* mc will be inconsistent if caller does mc_snum++ as above */
|
||||||
|
mc->mc_flags &= ~(C_INITIALIZED|C_EOF);
|
||||||
return rc;
|
return rc;
|
||||||
|
}
|
||||||
|
|
||||||
mdb_cursor_push(mc, mp);
|
mdb_cursor_push(mc, mp);
|
||||||
if (!move_right)
|
if (!move_right)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue