mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-01-09 00:14:25 -05:00
Fix dupsort fetch
This commit is contained in:
parent
697e00a8e2
commit
11308a190d
1 changed files with 5 additions and 1 deletions
|
|
@ -2008,7 +2008,8 @@ mdb_cursor_set(MDB_cursor *cursor, MDB_val *key, MDB_val *data,
|
|||
cursor->mc_eof = 0;
|
||||
|
||||
if (data) {
|
||||
if ((rc = mdb_read_data(cursor->mc_txn, leaf, data)) != MDB_SUCCESS)
|
||||
MDB_val d2;
|
||||
if ((rc = mdb_read_data(cursor->mc_txn, leaf, &d2)) != MDB_SUCCESS)
|
||||
return rc;
|
||||
|
||||
if (cursor->mc_txn->mt_dbs[cursor->mc_dbi].md_flags & MDB_DUPSORT) {
|
||||
|
|
@ -2029,7 +2030,10 @@ mdb_cursor_set(MDB_cursor *cursor, MDB_val *key, MDB_val *data,
|
|||
if (rc != MDB_SUCCESS)
|
||||
return rc;
|
||||
}
|
||||
} else {
|
||||
*data = d2;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
rc = mdb_set_key(leaf, key);
|
||||
|
|
|
|||
Loading…
Reference in a new issue