- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 55 for syscall (0.22 sec)
-
cmd/xl-storage-errors.go
package cmd import ( "errors" "os" "runtime" "syscall" ) // No space left on device error func isSysErrNoSpace(err error) bool { return errors.Is(err, syscall.ENOSPC) } // Invalid argument, unsupported flags such as O_DIRECT func isSysErrInvalidArg(err error) bool { return errors.Is(err, syscall.EINVAL) } // Input/output error func isSysErrIO(err error) bool {
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Mon Mar 06 16:56:29 GMT 2023 - 3.8K bytes - Viewed (0) -
cmd/xl-storage-errors_test.go
package cmd import ( "os" "runtime" "syscall" "testing" ) func TestSysErrors(t *testing.T) { pathErr := &os.PathError{Err: syscall.ENAMETOOLONG} ok := isSysErrTooLong(pathErr) if !ok { t.Fatalf("Unexpected error expecting %s", syscall.ENAMETOOLONG) } pathErr = &os.PathError{Err: syscall.ENOTDIR} ok = isSysErrNotDir(pathErr) if !ok {
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Fri Apr 23 18:58:53 GMT 2021 - 1.7K bytes - Viewed (0) -
internal/lock/lock_windows.go
fallthrough case syscall.O_WRONLY | syscall.O_CREAT: access = syscall.GENERIC_READ | syscall.GENERIC_WRITE case syscall.O_WRONLY | syscall.O_CREAT | syscall.O_APPEND: access = syscall.FILE_APPEND_DATA default: return nil, fmt.Errorf("Unsupported flag (%d)", flag) } var createflag uint32 switch { case flag&syscall.O_CREAT == syscall.O_CREAT: createflag = syscall.OPEN_ALWAYS default:
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Wed Oct 18 18:08:15 GMT 2023 - 7.9K bytes - Viewed (0) -
internal/http/check_port_linux.go
lc := &net.ListenConfig{ Control: func(network, address string, c syscall.RawConn) error { c.Control(func(fdPtr uintptr) { if opts.Interface != "" { // When interface is specified look for specifically port availability on // the specified interface if any. _ = syscall.SetsockoptString(int(fdPtr), syscall.SOL_SOCKET, syscall.SO_BINDTODEVICE, opts.Interface) } }) return nil }, }
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Wed May 03 21:12:25 GMT 2023 - 1.9K bytes - Viewed (0) -
internal/lock/lock_nix.go
fallthrough case syscall.O_RDWR | syscall.O_CREAT: lockType |= syscall.LOCK_EX default: return nil, &os.PathError{ Op: "open", Path: path, Err: syscall.EINVAL, } } f, err := os.OpenFile(path, flag|syscall.O_SYNC, perm) if err != nil { return nil, err } if err = syscall.Flock(int(f.Fd()), lockType); err != nil { f.Close() if err == syscall.EWOULDBLOCK { err = ErrAlreadyLocked
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Thu Aug 19 01:35:22 GMT 2021 - 2.8K bytes - Viewed (0) -
cmd/os-rename_linux.go
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Thu Feb 15 01:09:38 GMT 2024 - 999 bytes - Viewed (0) -
internal/disk/stat_bsd.go
// along with this program. If not, see <http://www.gnu.org/licenses/>. package disk import ( "errors" "fmt" "syscall" ) // GetInfo returns total and free bytes available in a directory, e.g. `/`. func GetInfo(path string, _ bool) (info Info, err error) { s := syscall.Statfs_t{} err = syscall.Statfs(path, &s) if err != nil { return Info{}, err } reservedBlocks := s.Bfree - s.Bavail info = Info{
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Mon Feb 26 19:34:50 GMT 2024 - 1.7K bytes - Viewed (0) -
internal/disk/type_windows.go
// // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see <http://www.gnu.org/licenses/>. package disk import ( "path/filepath" "syscall" "unsafe" ) // GetVolumeInformation provides windows drive volume information. var GetVolumeInformation = kernel32.NewProc("GetVolumeInformationW")
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Sun Jan 02 17:15:06 GMT 2022 - 2.2K bytes - Viewed (0) -
internal/disk/disk_unix.go
package disk import ( "syscall" ) // SameDisk reports whether di1 and di2 describe the same disk. func SameDisk(disk1, disk2 string) (bool, error) { st1 := syscall.Stat_t{} st2 := syscall.Stat_t{} if err := syscall.Stat(disk1, &st1); err != nil { return false, err } if err := syscall.Stat(disk2, &st2); err != nil { return false, err }
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Thu Aug 19 01:35:22 GMT 2021 - 1.2K bytes - Viewed (0) -
cmd/is-dir-empty_linux.go
Go - Registered: Sun May 05 19:28:20 GMT 2024 - Last Modified: Fri Apr 05 15:17:08 GMT 2024 - 1.4K bytes - Viewed (0)