mirror of
https://github.com/octoleo/syncthing.git
synced 2024-11-09 14:50:56 +00:00
Don't set permissions 000 on directories with NoPermissionBits set (ref #284)
This commit is contained in:
parent
c6ba0208d0
commit
cfd1fdb38e
@ -258,7 +258,7 @@ func (p *puller) fixupDirectories() {
|
||||
return nil
|
||||
}
|
||||
|
||||
if !scanner.PermsEqual(cur.Flags, uint32(info.Mode())) {
|
||||
if !p.repoCfg.IgnorePerms && protocol.HasPermissionBits(cur.Flags) && !scanner.PermsEqual(cur.Flags, uint32(info.Mode())) {
|
||||
err := os.Chmod(path, os.FileMode(cur.Flags)&os.ModePerm)
|
||||
if err != nil {
|
||||
l.Warnf("Restoring folder flags: %q: %v", path, err)
|
||||
|
Loading…
Reference in New Issue
Block a user