From: Hallvard Furuseth Date: Sat, 4 Jul 2015 11:48:06 +0000 (+0200) Subject: Simpler mdb_drop(). X-Git-Tag: LMDB_0.9.17~73 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=06df0a4655ec12ac17f4a0264427a62820859d7a;p=openldap Simpler mdb_drop(). MDB_DBI_CHANGED(,MAIN_DBI) is never true. --- diff --git a/libraries/liblmdb/mdb.c b/libraries/liblmdb/mdb.c index 774ba9021b..46555013c6 100644 --- a/libraries/liblmdb/mdb.c +++ b/libraries/liblmdb/mdb.c @@ -9511,7 +9511,7 @@ int mdb_drop(MDB_txn *txn, MDB_dbi dbi, int del) if (F_ISSET(txn->mt_flags, MDB_TXN_RDONLY)) return EACCES; - if (dbi > MAIN_DBI && TXN_DBI_CHANGED(txn, dbi)) + if (TXN_DBI_CHANGED(txn, dbi)) return MDB_BAD_DBI; rc = mdb_cursor_open(txn, dbi, &mc);