This forces all syscall functions, notably filesystem, to return numeric codes as opposed to mapping in two different areas. The result of this change is better consolidation in call sites of `sysfs.FS`, while further refactoring is needed to address consolidation of file errors. Signed-off-by: Adrian Cole <adrian@tetrate.io>
15 lines
323 B
Go
15 lines
323 B
Go
package platform
|
|
|
|
import (
|
|
"io/fs"
|
|
"syscall"
|
|
)
|
|
|
|
// Fdatasync is like syscall.Fdatasync except that's only defined in linux.
|
|
//
|
|
// Note: This returns with no error instead of syscall.ENOSYS when
|
|
// unimplemented. This prevents fake filesystems from erring.
|
|
func Fdatasync(f fs.File) syscall.Errno {
|
|
return fdatasync(f)
|
|
}
|