This website works better with JavaScript.
Home
Help
Sign In
zolfa
/
tendermint
Watch
1
Star
0
Fork
0
Code
Issues
0
Pull Requests
0
Projects
0
Releases
221
Wiki
Activity
Browse Source
db: sort keys for memdb iterator
pull/1842/head
Ethan Buchman
7 years ago
parent
2442a0a698
commit
135a1a7cd7
1 changed files
with
3 additions
and
0 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+3
-0
db/mem_db.go
+ 3
- 0
db/mem_db.go
View File
@ -2,6 +2,7 @@ package db
import
(
"fmt"
"sort"
"strings"
"sync"
)
@ -127,6 +128,8 @@ func (db *MemDB) IteratorPrefix(prefix []byte) Iterator {
it
.
keys
=
append
(
it
.
keys
,
key
)
}
}
// and we need to sort them
sort
.
Strings
(
it
.
keys
)
return
it
}
Write
Preview
Loading…
Cancel
Save