mirror of
https://github.com/isar/libmdbx.git
synced 2025-01-06 17:34:14 +08:00
mdbx: backport - Tweak MDB_PREV_MULTIPLE for uninit'd cursor.
Change-Id: I1f07e7c4d80631a1a0b2c70a936ef7b458baa11a
This commit is contained in:
parent
9d775b0a36
commit
ded1ada9eb
6
mdb.c
6
mdb.c
@ -6420,8 +6420,10 @@ fetchm:
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (!(mc->mc_flags & C_INITIALIZED))
|
if (!(mc->mc_flags & C_INITIALIZED))
|
||||||
rc = mdb_cursor_first(mc, key, data);
|
rc = mdb_cursor_last(mc, key, data);
|
||||||
else {
|
else
|
||||||
|
rc = MDB_SUCCESS;
|
||||||
|
if (rc == MDB_SUCCESS) {
|
||||||
MDB_cursor *mx = &mc->mc_xcursor->mx_cursor;
|
MDB_cursor *mx = &mc->mc_xcursor->mx_cursor;
|
||||||
if (mx->mc_flags & C_INITIALIZED) {
|
if (mx->mc_flags & C_INITIALIZED) {
|
||||||
rc = mdb_cursor_sibling(mx, 0);
|
rc = mdb_cursor_sibling(mx, 0);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user