Writing contents of buffer to writer even if there was an error

This commit is contained in:
Diptanu Choudhury
2016-01-13 11:38:43 -08:00
parent 8636fb61f7
commit 6604ef5be1

View File

@@ -262,11 +262,8 @@ func (d *AllocDir) FSReadAt(allocID string, path string, offset int64, limit int
return err
}
n, err := f.ReadAt(buf, offset)
if err != nil {
return err
}
w.Write(buf[:n])
return nil
return err
}
func fileCopy(src, dst string, perm os.FileMode) error {