local/sftp: Remove unneeded stat() call

This commit is contained in:
Alexander Neumann 2017-07-20 22:17:47 +02:00
parent c40b3d3983
commit 9842eff887
4 changed files with 5 additions and 18 deletions

View file

@ -9,6 +9,6 @@ import (
)
// set file to readonly
func setNewFileMode(f string, fi os.FileInfo) error {
return fs.Chmod(f, fi.Mode()&os.FileMode(^uint32(0222)))
func setNewFileMode(f string, mode os.FileMode) error {
return fs.Chmod(f, mode)
}