We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I found the test code below can cause the panic of DB, is any wrong with the test code?
type ritem struct { Key string Value []byte } base := []byte{1, 0, 1, 0} key := append([]byte{}, base...) minKey := []byte{1, 0, 1} schema := &memdb.DBSchema{ Tables: map[string]*memdb.TableSchema{ "0": &memdb.TableSchema{ Name: "0", Indexes: map[string]*memdb.IndexSchema{ "id": &memdb.IndexSchema{ Name: "id", Unique: true, Indexer: &memdb.StringFieldIndex{Field: "Key"}, }, }, }, }, } mdb, err := memdb.NewMemDB(schema) assert.Nil(t, err) txn := mdb.Txn(true) txn.Insert("0", &ritem{Key: string(key), Value: []byte("1")}) txn.Insert("0", &ritem{Key: string(append(key, byte(1))), Value: []byte("1")}) txn.Commit() txn = mdb.Txn(false) defer txn.Abort() resIter, err := txn.LowerBound("0", "id", string(minKey)) // panic happened here assert.Nil(t, err)
The text was updated successfully, but these errors were encountered:
It is related to the issue in hashicorp/go-immutable-radix#28 and could be fixed by the pr hashicorp/go-immutable-radix#35
Sorry, something went wrong.
No branches or pull requests
I found the test code below can cause the panic of DB, is any wrong with the test code?
The text was updated successfully, but these errors were encountered: