Fix osspecifics_darwin.go

This commit is contained in:
AlexSSD7 2023-09-27 09:51:56 +01:00
commit b5df721e44

View file

@ -16,6 +16,13 @@
// go:build darwin // go:build darwin
package osspecifics
import (
"github.com/pkg/errors"
"golang.org/x/sys/unix"
)
func getDeviceLogicalBlockSizeInner(fd uintptr) (int64, error) { func getDeviceLogicalBlockSizeInner(fd uintptr) (int64, error) {
bs, err := unix.IoctlGetInt(int(fd.Fd()), 0x40046418) // Syscall code for DKIOGETBLOCKSIZE bs, err := unix.IoctlGetInt(int(fd.Fd()), 0x40046418) // Syscall code for DKIOGETBLOCKSIZE
if err != nil { if err != nil {