[email protected] wrote: > Full_Name: Max Bolingbroke > Version: LMDB HEAD > OS: OS X > URL: ftp://ftp.openldap.org/incoming/max-bolingbroke-140730.patch > Submission from: (NULL) (81.111.197.81) > > > 1. When using mdb_cursor_get(MDB_FIRST_DUP) or mdb_cursor_get(MDB_LAST_DUP) > on a > cursor that is currently positioned on a key without any duplicate values, > then > we should return MDB_NOTFOUND rather than EINVAL.
Rethinking this, I think it should simply return the existing non-dup value. mdb_cursor_count already handles a similar situation, returning 1 for the count when there are no dups. > 2. When using mdb_cursor_get(MDB_NEXT_DUP) on a cursor that is currently > positioned on the final key in the database, we should not return MDB_NOTFOUND > unless the value we are on is actually the final one within that key. OK. -- -- Howard Chu CTO, Symas Corp. http://www.symas.com Director, Highland Sun http://highlandsun.com/hyc/ Chief Architect, OpenLDAP http://www.openldap.org/project/
