- Sort Score
- Result 10 results
- Languages All
Results 51 - 60 of 159 for fd (0.04 sec)
-
src/runtime/sys_openbsd2.go
//go:nosplit //go:cgo_unsafe_args func closefd(fd int32) int32 { return libcCall(unsafe.Pointer(abi.FuncPCABI0(close_trampoline)), unsafe.Pointer(&fd)) } func close_trampoline() //go:nosplit //go:cgo_unsafe_args func read(fd int32, p unsafe.Pointer, n int32) int32 { ret := libcCall(unsafe.Pointer(abi.FuncPCABI0(read_trampoline)), unsafe.Pointer(&fd)) KeepAlive(p) return ret } func read_trampoline()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 25 19:53:03 UTC 2024 - 8.7K bytes - Viewed (0) -
src/runtime/vdso_freebsd_x86.go
var devPath [len(hpetDevPath)]byte copy(devPath[:], hpetDevPath) devPath[9] = digits[idx] fd := open(&devPath[0], 0 /* O_RDONLY */ |_O_CLOEXEC, 0) if fd < 0 { atomic.Casuintptr(&hpetDevMap[idx], 0, ^uintptr(0)) return } addr, mmapErr := mmap(nil, physPageSize, _PROT_READ, _MAP_SHARED, fd, 0) closefd(fd) newP := uintptr(addr) if mmapErr != 0 { newP = ^uintptr(0) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 25 19:53:03 UTC 2024 - 1.9K bytes - Viewed (0) -
cni/pkg/nodeagent/netns_linux.go
} return &NetnsWrapper{innerNetns: n, inode: i}, nil } func NetnsSet(n NetnsFd) error { if err := unix.Setns(int(n.Fd()), unix.CLONE_NEWNET); err != nil { return fmt.Errorf("Error switching to ns fd %v: %v", n.Fd(), err) } return nil } // inspired by netns.Do() but with an existing fd. func NetnsDo(fdable NetnsFd, toRun func() error) error { containedCall := func() error { threadNS, err := netns.GetCurrentNS()
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Wed Jan 31 10:05:36 UTC 2024 - 2.7K bytes - Viewed (0) -
src/os/writeto_linux_test.go
} if hook.called && hook.srcfd != int(src.Fd()) { t.Fatalf("wrong source file descriptor: got %d, want %d", hook.srcfd, src.Fd()) } sc, ok := dst.(syscall.Conn) if !ok { t.Fatalf("destination is not a syscall.Conn") } rc, err := sc.SyscallConn() if err != nil { t.Fatalf("destination SyscallConn error: %v", err) } if err = rc.Control(func(fd uintptr) { if hook.called && hook.dstfd != int(fd) {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 26 18:12:56 UTC 2024 - 4K bytes - Viewed (0) -
tools/istio-iptables/pkg/validation/vld_unix.go
func GetOriginalDestination(conn net.Conn) (daddr net.IP, dport uint16, err error) { // obtain os fd from Conn tcp, ok := conn.(*net.TCPConn) if !ok { err = errors.New("socket is not tcp") return } file, err := tcp.File() if err != nil { return } defer file.Close() fd := file.Fd() // Detect underlying ip is v4 or v6 ip := conn.RemoteAddr().(*net.TCPAddr).IP isIpv4 := false
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Thu Feb 08 03:52:24 UTC 2024 - 3K bytes - Viewed (0) -
src/net/sendfile_windows.go
func sendFile(fd *netFD, r io.Reader) (written int64, err error, handled bool) { var n int64 = 0 // by default, copy until EOF. lr, ok := r.(*io.LimitedReader) if ok { n, r = lr.N, lr.R if n <= 0 { return 0, nil, true } } f, ok := r.(*os.File) if !ok { return 0, nil, false } written, err = poll.SendFile(&fd.pfd, syscall.Handle(f.Fd()), n) if err != nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 26 18:12:56 UTC 2024 - 1.1K bytes - Viewed (0) -
src/runtime/stubs2.go
func read(fd int32, p unsafe.Pointer, n int32) int32 func closefd(fd int32) int32 func exit(code int32) func usleep(usec uint32) //go:nosplit func usleep_no_g(usec uint32) { usleep(usec) } // write1 calls the write system call. // It returns a non-negative number of bytes written or a negative errno value. // //go:noescape func write1(fd uintptr, p unsafe.Pointer, n int32) int32
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 25 19:53:03 UTC 2024 - 1.1K bytes - Viewed (0) -
src/runtime/netpoll_wasip1.go
widx = to } pd.user = uint32(ridx)<<16 | uint32(widx) if to != disarmed { subs[to], subs[from] = subs[from], subs[to] } } func netpollclose(fd uintptr) int32 { lock(&mtx) for i := 0; i < len(pds); i++ { if pds[i].fd == fd { netpolldisarm(pds[i], 'r'+'w') pds[i] = pds[len(pds)-1] pds = pds[:len(pds)-1] break } } unlock(&mtx) return 0 }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Mar 27 18:23:49 UTC 2024 - 6.1K bytes - Viewed (0) -
src/runtime/os_aix.go
} return ts.tv_sec, int32(ts.tv_nsec) } //go:nosplit func fcntl(fd, cmd, arg int32) (int32, int32) { r, errno := syscall3(&libc_fcntl, uintptr(fd), uintptr(cmd), uintptr(arg)) return int32(r), int32(errno) } //go:nosplit func setNonblock(fd int32) { flags, _ := fcntl(fd, _F_GETFL, 0) if flags != -1 { fcntl(fd, _F_SETFL, flags|_O_NONBLOCK) } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 25 19:53:03 UTC 2024 - 8.9K bytes - Viewed (0) -
src/runtime/netpoll_kqueue.go
} closeonexec(kq) addWakeupEvent(kq) } func netpollopen(fd uintptr, pd *pollDesc) int32 { // Arm both EVFILT_READ and EVFILT_WRITE in edge-triggered mode (EV_CLEAR) // for the whole fd lifetime. The notifications are automatically unregistered // when fd is closed. var ev [2]keventt *(*uintptr)(unsafe.Pointer(&ev[0].ident)) = fd ev[0].filter = _EVFILT_READ ev[0].flags = _EV_ADD | _EV_CLEAR ev[0].fflags = 0
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Apr 12 21:17:22 UTC 2024 - 4.6K bytes - Viewed (0)