mirror of
https://github.com/octoleo/syncthing.git
synced 2024-12-22 19:08:58 +00:00
parent
2bbd2d6ed1
commit
c120c3a403
@ -255,11 +255,14 @@ func (w *walker) createFSWalkFn(ctx context.Context, fsChan chan<- fsWalkResult)
|
||||
skip = fs.SkipDir
|
||||
}
|
||||
|
||||
if path == "." {
|
||||
if err != nil {
|
||||
fsWalkError(ctx, fsChan, path, err)
|
||||
return skip
|
||||
if err != nil {
|
||||
if sendErr := fsWalkError(ctx, fsChan, path, err); sendErr != nil {
|
||||
return sendErr
|
||||
}
|
||||
return skip
|
||||
}
|
||||
|
||||
if path == "." {
|
||||
return nil
|
||||
}
|
||||
|
||||
@ -282,13 +285,6 @@ func (w *walker) createFSWalkFn(ctx context.Context, fsChan chan<- fsWalkResult)
|
||||
return skip
|
||||
}
|
||||
|
||||
if err != nil {
|
||||
if sendErr := fsWalkError(ctx, fsChan, path, err); sendErr != nil {
|
||||
return sendErr
|
||||
}
|
||||
return skip
|
||||
}
|
||||
|
||||
if !utf8.ValidString(path) {
|
||||
if err := fsWalkError(ctx, fsChan, path, errors.New("path isn't a valid utf8 string")); err != nil {
|
||||
return err
|
||||
|
Loading…
Reference in New Issue
Block a user