mirror of
https://github.com/isar/libmdbx.git
synced 2025-01-04 17:34:14 +08:00
lmdb: ITS#8181 reflect changes for mdb_chk.
Change-Id: I9c7a1323af5d62b549bc2430c8cb8bf5c5686bee
This commit is contained in:
parent
be27186f76
commit
2fdf96cf4f
@ -279,7 +279,7 @@ static long handle_maindb(size_t record_number, MDB_val *key, MDB_val* data) {
|
|||||||
|
|
||||||
rc = process_db(-1, name, handle_userdb, 0);
|
rc = process_db(-1, name, handle_userdb, 0);
|
||||||
free(name);
|
free(name);
|
||||||
if (rc != MDB_BAD_DBI)
|
if (rc != MDB_INCOMPATIBLE)
|
||||||
return rc;
|
return rc;
|
||||||
|
|
||||||
return handle_userdb(record_number, key, data);
|
return handle_userdb(record_number, key, data);
|
||||||
@ -302,7 +302,7 @@ static long process_db(MDB_dbi dbi, char *name, visitor *handler, int silent)
|
|||||||
if (0 > (int) dbi) {
|
if (0 > (int) dbi) {
|
||||||
rc = mdb_dbi_open(txn, name, 0, &dbi);
|
rc = mdb_dbi_open(txn, name, 0, &dbi);
|
||||||
if (rc) {
|
if (rc) {
|
||||||
if (!name || rc != MDB_BAD_DBI) /* LY: mainDB's record is not a user's DB. */ {
|
if (!name || rc != MDB_INCOMPATIBLE) /* LY: mainDB's record is not a user's DB. */ {
|
||||||
error(" - mdb_open '%s' failed, error %d %s\n",
|
error(" - mdb_open '%s' failed, error %d %s\n",
|
||||||
name ? name : "main", rc, mdb_strerror(rc));
|
name ? name : "main", rc, mdb_strerror(rc));
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user