mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-26 09:39:45 -05:00
ITS#8109 fix mdb_cursor_del0 on empty DB
This commit is contained in:
parent
4c62fde880
commit
f4cab2994f
1 changed files with 7 additions and 0 deletions
|
|
@ -7963,6 +7963,13 @@ mdb_cursor_del0(MDB_cursor *mc)
|
|||
MDB_cursor *m2, *m3;
|
||||
MDB_dbi dbi = mc->mc_dbi;
|
||||
|
||||
/* DB is totally empty now, just bail out.
|
||||
* Other cursors adjustments were already done
|
||||
* by mdb_rebalance and aren't needed here.
|
||||
*/
|
||||
if (!mc->mc_snum)
|
||||
return rc;
|
||||
|
||||
mp = mc->mc_pg[mc->mc_top];
|
||||
nkeys = NUMKEYS(mp);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue