- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 55 for Syscall (0.04 sec)
-
internal/http/dial_linux.go
} if opts.NoDelay { _ = syscall.SetsockoptInt(fd, syscall.IPPROTO_TCP, unix.TCP_NODELAY, 1) _ = syscall.SetsockoptInt(fd, syscall.SOL_TCP, unix.TCP_CORK, 0) } // Enable TCP open // https://lwn.net/Articles/508865/ - 32k queue size. _ = syscall.SetsockoptInt(fd, syscall.SOL_TCP, unix.TCP_FASTOPEN, 32*1024) // Enable TCP fast connect
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Tue Jul 23 10:53:03 UTC 2024 - 5K bytes - Viewed (0) -
src/bytes/boundary_test.go
func dangerousSlice(t *testing.T) []byte { pagesize := syscall.Getpagesize() b, err := syscall.Mmap(0, 0, 3*pagesize, syscall.PROT_READ|syscall.PROT_WRITE, syscall.MAP_ANONYMOUS|syscall.MAP_PRIVATE) if err != nil { t.Fatalf("mmap failed %s", err) } err = syscall.Mprotect(b[:pagesize], syscall.PROT_NONE) if err != nil { t.Fatalf("mprotect low failed %s\n", err) } err = syscall.Mprotect(b[2*pagesize:], syscall.PROT_NONE)
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Thu Nov 30 20:05:58 UTC 2023 - 2.8K 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
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 19 01:35:22 UTC 2021 - 2.8K 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:
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Oct 18 18:08:15 UTC 2023 - 7.9K bytes - Viewed (0) -
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 {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Mar 06 16:56:29 UTC 2023 - 3.8K bytes - Viewed (0) -
internal/lock/lock_solaris.go
package lock import ( "os" "syscall" ) // lockedOpenFile is an internal function. func lockedOpenFile(path string, flag int, perm os.FileMode, rlockType int) (*LockedFile, error) { var lockType int16 switch flag { case syscall.O_RDONLY: lockType = syscall.F_RDLCK case syscall.O_WRONLY: fallthrough case syscall.O_RDWR: fallthrough case syscall.O_WRONLY | syscall.O_CREAT: fallthrough
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sun Jan 02 17:15:06 UTC 2022 - 2.8K bytes - Viewed (0) -
internal/http/dial_others.go
package http import ( "context" "net" "syscall" "time" ) // TODO: if possible implement for non-linux platforms, not a priority at the moment // //nolint:unused func setTCPParametersFn(opts TCPOptions) func(network, address string, c syscall.RawConn) error { return func(network, address string, c syscall.RawConn) error { return nil } }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Apr 24 04:08:47 UTC 2024 - 1.6K bytes - Viewed (0) -
internal/disk/stat_freebsd.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 - uint64(s.Bavail) info = Info{
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Feb 26 19:34:50 UTC 2024 - 1.7K bytes - Viewed (0) -
internal/disk/stat_linux_s390x.go
if !ok { return "UNKNOWN" } return fsTypeString } // 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{ Total: uint64(s.Frsize) * (s.Blocks - reservedBlocks),
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Feb 26 19:34:50 UTC 2024 - 2.6K bytes - Viewed (0) -
internal/config/errors-utils.go
if e, ok := err.(Err); ok { return e } // Show a generic message for known golang errors if errors.Is(err, syscall.EADDRINUSE) { return ErrPortAlreadyInUse(err).Msg("Specified port is already in use") } else if errors.Is(err, syscall.EACCES) || errors.Is(err, syscall.EPERM) { if netErr, ok := err.(*net.OpError); ok { return ErrPortAccess(netErr).Msg("Insufficient permissions to use specified port") }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Aug 14 17:11:51 UTC 2024 - 3.8K bytes - Viewed (0)