fileutil_netbsd.go 699 B

1234567891011121314151617181920212223242526272829
  1. // Copyright (c) 2014 The fileutil Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style
  3. // license that can be found in the LICENSE file.
  4. // +build !arm
  5. package fileutil
  6. import (
  7. "io"
  8. "os"
  9. )
  10. const hasPunchHole = false
  11. // PunchHole deallocates space inside a file in the byte range starting at
  12. // offset and continuing for len bytes. Similar to FreeBSD, this is
  13. // unimplemented.
  14. func PunchHole(f *os.File, off, len int64) error {
  15. return nil
  16. }
  17. // Unimplemented on NetBSD.
  18. func Fadvise(f *os.File, off, len int64, advice FadviseAdvice) error {
  19. return nil
  20. }
  21. // IsEOF reports whether err is an EOF condition.
  22. func IsEOF(err error) bool { return err == io.EOF }