mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-28 10:39:34 -05:00
Fix mdb_drop return
This commit is contained in:
parent
a103a64434
commit
f0c9d77326
1 changed files with 2 additions and 2 deletions
|
|
@ -5910,8 +5910,7 @@ int mdb_drop(MDB_txn *txn, MDB_dbi dbi, int del)
|
|||
|
||||
rc = mdb_drop0(mc, mc->mc_db->md_flags & MDB_DUPSORT);
|
||||
if (rc)
|
||||
mdb_cursor_close(mc);
|
||||
return rc;
|
||||
goto leave;
|
||||
|
||||
/* Can't delete the main DB */
|
||||
if (del && dbi > MAIN_DBI) {
|
||||
|
|
@ -5927,6 +5926,7 @@ int mdb_drop(MDB_txn *txn, MDB_dbi dbi, int del)
|
|||
txn->mt_dbs[dbi].md_entries = 0;
|
||||
txn->mt_dbs[dbi].md_root = P_INVALID;
|
||||
}
|
||||
leave:
|
||||
mdb_cursor_close(mc);
|
||||
return rc;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue