Zeros function improved (do we need this?)

This commit is contained in:
Dionysus 2023-12-27 15:21:33 -05:00
parent 2f2090929c
commit bd9f68282c
Signed by: acidvegas
GPG Key ID: EF4B922DB85DC9DE

View File

@ -86,12 +86,8 @@ func Zeros(path string, size int64) error {
}
defer file.Close()
offset, err := file.Seek(0, 0)
if err != nil {
return err
}
buff := make([]byte, size)
file.WriteAt(buff, offset)
file.WriteAt(buff, 0)
return nil
}