mirror of
https://github.com/rclone/rclone.git
synced 2026-01-04 17:43:50 +00:00
Fixes after running errcheck
This commit is contained in:
@@ -217,12 +217,15 @@ func (f *FsLocal) readPrecision() (precision time.Duration) {
|
||||
}
|
||||
path := fd.Name()
|
||||
// fmt.Println("Created temp file", path)
|
||||
fd.Close()
|
||||
err = fd.Close()
|
||||
if err != nil {
|
||||
return time.Second
|
||||
}
|
||||
|
||||
// Delete it on return
|
||||
defer func() {
|
||||
// fmt.Println("Remove temp file")
|
||||
os.Remove(path)
|
||||
_ = os.Remove(path) // ignore error
|
||||
}()
|
||||
|
||||
// Find the minimum duration we can detect
|
||||
|
||||
Reference in New Issue
Block a user