Model.internalScanFolder: Don't ignore special .stfolder and .stignore files.

Fixes #2151.

Since Walk.walkAndHashFiles ignores .stfolder and .stignore, they will
never be found by fs.Get(protocol.LocalDeviceID, sub) in
Model.internalScanFolder. As a result, when asked to scan those subs
we end up scanning the whole folder.
This commit is contained in:
Michael Ploujnikov 2016-01-22 22:37:58 -05:00
parent 6c33188af3
commit 49601a63c8

View File

@ -1323,7 +1323,7 @@ func (m *Model) internalScanFolderSubs(folder string, subs []string) error {
var unifySubs []string
nextSub:
for _, sub := range subs {
for sub != "" {
for sub != "" && sub != ".stfolder" && sub != ".stignore" {
if _, ok = fs.Get(protocol.LocalDeviceID, sub); ok {
break
}