mirror of
https://github.com/octoleo/syncthing.git
synced 2025-01-03 15:17:25 +00:00
lib/db: Actually delete the correct sequence prefix
This commit is contained in:
parent
506181599c
commit
fb198a0645
@ -541,7 +541,7 @@ func (db *Instance) dropFolder(folder []byte) {
|
|||||||
|
|
||||||
// Remove all sequences related to the folder
|
// Remove all sequences related to the folder
|
||||||
sequenceKey := db.sequenceKey([]byte(folder), 0)
|
sequenceKey := db.sequenceKey([]byte(folder), 0)
|
||||||
dbi = t.NewIterator(util.BytesPrefix(sequenceKey[:4]), nil)
|
dbi = t.NewIterator(util.BytesPrefix(sequenceKey[:keyPrefixLen+keyFolderLen]), nil)
|
||||||
for dbi.Next() {
|
for dbi.Next() {
|
||||||
db.Delete(dbi.Key(), nil)
|
db.Delete(dbi.Key(), nil)
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user