https://bugs.openldap.org/show_bug.cgi?id=9461
Issue ID: 9461 Summary: Deletion causes cursor to repeat Product: LMDB Version: 0.9.27 Hardware: All OS: All Status: UNCONFIRMED Severity: normal Priority: --- Component: liblmdb Assignee: bugs@openldap.org Reporter: github@nicwatson.org Target Milestone: ---
Created attachment 795 --> https://bugs.openldap.org/attachment.cgi?id=795&action=edit repro of cursor delete bug
See attached source code for reproduction. The test behaves correctly in 0.9.26 and fails in 0.9.27 and 0.9.28.
The failing sequence is:
1. In a dupsort DB, create two different keys and values. 2. Create a cursor, setting the position to the second key. 3. Delete the first key. 4. Have the cursor get the next key. mdb_get_key will return the second key instead of returning MDB_NOT_FOUND.
https://bugs.openldap.org/show_bug.cgi?id=9461
Howard Chu hyc@openldap.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |TEST Status|UNCONFIRMED |RESOLVED
--- Comment #1 from Howard Chu hyc@openldap.org --- (In reply to github@nicwatson.org from comment #0)
Created attachment 795 [details] repro of cursor delete bug
Thanks for the report. Broken by the patch for ITS#9376. Fixed now in git.
See attached source code for reproduction. The test behaves correctly in 0.9.26 and fails in 0.9.27 and 0.9.28.
The failing sequence is:
- In a dupsort DB, create two different keys and values.
- Create a cursor, setting the position to the second key.
- Delete the first key.
- Have the cursor get the next key. mdb_get_key will return the second key
instead of returning MDB_NOT_FOUND.
https://bugs.openldap.org/show_bug.cgi?id=9461
Quanah Gibson-Mount quanah@openldap.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Target Milestone|--- |0.9.29
https://bugs.openldap.org/show_bug.cgi?id=9461
--- Comment #2 from Quanah Gibson-Mount quanah@openldap.org --- re0.9:
commit 40585b483976d9062e6c971df285f911512ecd5e Author: Howard Chu hyc@openldap.org Date: Tue Feb 9 23:38:06 2021 +0000
mdb.master:
commit 917e4f1d142731e67d43e43c957432f3f8f31bf9 Author: Howard Chu hyc@openldap.org
mdb.master3:
commit 336d71714708ef02d6376621158ce0feb3578a5e Author: Howard Chu hyc@openldap.org
https://bugs.openldap.org/show_bug.cgi?id=9461
--- Comment #3 from eras@gentoo.org --- lmdb-0.9.28 with patch applied fails tests with:
[...] key: 0x7f508b11a8a4 3f1 , data: 0x7f508b11a8a8 3f1 1009 foo bar key: 0x7f508b11a878 3f3 , data: 0x7f508b11a87c 3f3 1011 foo bar key: 0x7f508b11a84c 3fa , data: 0x7f508b11a850 3fa 1018 foo bar make: *** [Makefile:62: test] Error 139
https://bugs.openldap.org/show_bug.cgi?id=9461
--- Comment #4 from Howard Chu hyc@openldap.org --- (In reply to eras from comment #3)
lmdb-0.9.28 with patch applied fails tests with:
[...] key: 0x7f508b11a8a4 3f1 , data: 0x7f508b11a8a8 3f1 1009 foo bar key: 0x7f508b11a878 3f3 , data: 0x7f508b11a87c 3f3 1011 foo bar key: 0x7f508b11a84c 3fa , data: 0x7f508b11a850 3fa 1018 foo bar make: *** [Makefile:62: test] Error 139
Thanks, typo when switching between branches. Fixed now.
https://bugs.openldap.org/show_bug.cgi?id=9461
Quanah Gibson-Mount quanah@openldap.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |VERIFIED Resolution|TEST |FIXED