Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 52 for Setsockopt (0.48 sec)

  1. src/net/tcpsockopt_unix.go

    	runtime.KeepAlive(fd)
    	return wrapSyscallError("setsockopt", err)
    }
    
    func setKeepAliveCount(fd *netFD, n int) error {
    	if n == 0 {
    		n = defaultTCPKeepAliveCount
    	} else if n < 0 {
    		return nil
    	}
    
    	err := fd.pfd.SetsockoptInt(syscall.IPPROTO_TCP, syscall.TCP_KEEPCNT, n)
    	runtime.KeepAlive(fd)
    	return wrapSyscallError("setsockopt", err)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Apr 14 18:17:21 UTC 2024
    - 1.3K bytes
    - Viewed (0)
  2. src/net/tcpsockopt_solaris.go

    	secs := int(roundDurationUp(d, time.Second))
    	err := fd.pfd.SetsockoptInt(syscall.IPPROTO_TCP, sysTCP_KEEPIDLE, secs)
    	runtime.KeepAlive(fd)
    	return wrapSyscallError("setsockopt", err)
    }
    
    func setKeepAliveInterval(fd *netFD, d time.Duration) error {
    	if !unix.SupportTCPKeepAliveIdleIntvlCNT() {
    		return syscall.EPROTOTYPE
    	}
    
    	if d == 0 {
    		d = defaultTCPKeepAliveInterval
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 15 03:10:07 UTC 2024
    - 3.3K bytes
    - Viewed (0)
  3. src/internal/poll/sockoptip.go

    package poll
    
    import "syscall"
    
    // SetsockoptIPMreq wraps the setsockopt network call with an IPMreq argument.
    func (fd *FD) SetsockoptIPMreq(level, name int, mreq *syscall.IPMreq) error {
    	if err := fd.incref(); err != nil {
    		return err
    	}
    	defer fd.decref()
    	return syscall.SetsockoptIPMreq(fd.Sysfd, level, name, mreq)
    }
    
    // SetsockoptIPv6Mreq wraps the setsockopt network call with an IPv6Mreq argument.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Mar 29 16:24:51 UTC 2022
    - 817 bytes
    - Viewed (0)
  4. src/net/sockoptip_linux.go

    	runtime.KeepAlive(fd)
    	return wrapSyscallError("setsockopt", err)
    }
    
    func setIPv4MulticastLoopback(fd *netFD, v bool) error {
    	err := fd.pfd.SetsockoptInt(syscall.IPPROTO_IP, syscall.IP_MULTICAST_LOOP, boolint(v))
    	runtime.KeepAlive(fd)
    	return wrapSyscallError("setsockopt", err)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Feb 13 18:36:28 UTC 2017
    - 735 bytes
    - Viewed (0)
  5. src/net/tcpsockopt_windows.go

    	runtime.KeepAlive(fd)
    	return os.NewSyscallError("setsockopt", err)
    }
    
    func setKeepAliveCount(fd *netFD, n int) error {
    	if n == 0 {
    		n = defaultTCPKeepAliveCount
    	} else if n < 0 {
    		return nil
    	}
    
    	err := fd.pfd.SetsockoptInt(syscall.IPPROTO_TCP, windows.TCP_KEEPCNT, n)
    	runtime.KeepAlive(fd)
    	return os.NewSyscallError("setsockopt", err)
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 21 11:49:35 UTC 2024
    - 3.8K bytes
    - Viewed (0)
  6. src/net/sockopt_windows.go

    	}
    	if (sotype == syscall.SOCK_DGRAM || sotype == syscall.SOCK_RAW) && family != syscall.AF_UNIX && family != syscall.AF_INET6 {
    		// Allow broadcast.
    		return os.NewSyscallError("setsockopt", syscall.SetsockoptInt(s, syscall.SOL_SOCKET, syscall.SO_BROADCAST, 1))
    	}
    	return nil
    }
    
    func setDefaultListenerSockopts(s syscall.Handle) error {
    	// Windows will reuse recently-used addresses by default.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat May 09 00:33:27 UTC 2020
    - 1.5K bytes
    - Viewed (0)
  7. src/internal/poll/sockopt_unix.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    //go:build unix
    
    package poll
    
    import "syscall"
    
    // SetsockoptByte wraps the setsockopt network call with a byte argument.
    func (fd *FD) SetsockoptByte(level, name int, arg byte) error {
    	if err := fd.incref(); err != nil {
    		return err
    	}
    	defer fd.decref()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Mar 29 16:24:51 UTC 2022
    - 480 bytes
    - Viewed (0)
  8. src/syscall/badlinkname_unix.go

    // keep them accessible with pull linknames.
    // This may change in the future. Please do not depend on them
    // in new code.
    
    // golang.org/x/sys linknames getsockopt.
    // Do not remove or change the type signature.
    //
    //go:linkname getsockopt
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 22 20:12:46 UTC 2024
    - 679 bytes
    - Viewed (0)
  9. src/internal/poll/sockopt_linux.go

    // Copyright 2011 The Go Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package poll
    
    import "syscall"
    
    // SetsockoptIPMreqn wraps the setsockopt network call with an IPMreqn argument.
    func (fd *FD) SetsockoptIPMreqn(level, name int, mreq *syscall.IPMreqn) error {
    	if err := fd.incref(); err != nil {
    		return err
    	}
    	defer fd.decref()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Apr 13 03:26:58 UTC 2017
    - 490 bytes
    - Viewed (0)
  10. src/syscall/lsf_linux.go

    	var p SockFprog
    	p.Len = uint16(len(i))
    	p.Filter = (*SockFilter)(unsafe.Pointer(&i[0]))
    	return setsockopt(fd, SOL_SOCKET, SO_ATTACH_FILTER, unsafe.Pointer(&p), unsafe.Sizeof(p))
    }
    
    // Deprecated: Use golang.org/x/net/bpf instead.
    func DetachLsf(fd int) error {
    	var dummy int
    	return setsockopt(fd, SOL_SOCKET, SO_DETACH_FILTER, unsafe.Pointer(&dummy), unsafe.Sizeof(dummy))
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Aug 19 16:27:36 UTC 2022
    - 2.1K bytes
    - Viewed (0)
Back to top