mirror of
https://github.com/isar/libmdbx.git
synced 2025-01-06 19:34:15 +08:00
lmdb: Simpler mdb_drop().
MDB_DBI_CHANGED(,MAIN_DBI) is never true. Change-Id: I0d12b9965d8251908ec41d1febc6b5c354a93a01
This commit is contained in:
parent
6524dbf3a1
commit
9e52d29fd8
2
mdb.c
2
mdb.c
@ -9343,7 +9343,7 @@ int mdb_drop(MDB_txn *txn, MDB_dbi dbi, int del)
|
|||||||
if (F_ISSET(txn->mt_flags, MDB_TXN_RDONLY))
|
if (F_ISSET(txn->mt_flags, MDB_TXN_RDONLY))
|
||||||
return EACCES;
|
return EACCES;
|
||||||
|
|
||||||
if (dbi > MAIN_DBI && TXN_DBI_CHANGED(txn, dbi))
|
if (TXN_DBI_CHANGED(txn, dbi))
|
||||||
return MDB_BAD_DBI;
|
return MDB_BAD_DBI;
|
||||||
|
|
||||||
rc = mdb_cursor_open(txn, dbi, &mc);
|
rc = mdb_cursor_open(txn, dbi, &mc);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user