Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 10 for Closeonexec (0.32 sec)

  1. src/net/sock_cloexec_solaris.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    // This file implements sysSocket for platforms that provide a fast path for
    // setting SetNonblock and CloseOnExec, but don't necessarily support it.
    // Support for SOCK_* flags as part of the type parameter was added to Oracle
    // Solaris in the 11.4 release. Thus, on releases prior to 11.4, we fall back
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Apr 14 18:17:25 UTC 2024
    - 1.4K bytes
    - Viewed (0)
  2. src/internal/poll/sock_cloexec_solaris.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    // This file implements accept for platforms that provide a fast path for
    // setting SetNonblock and CloseOnExec, but don't necessarily have accept4.
    // The accept4(3c) function was added to Oracle Solaris in the Solaris 11.4.0
    // release. Thus, on releases prior to 11.4, we fall back to the combination
    // of accept(3c) and fcntl(2).
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Apr 14 18:17:25 UTC 2024
    - 1.5K bytes
    - Viewed (0)
  3. src/net/sock_cloexec.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    // This file implements sysSocket for platforms that provide a fast path for
    // setting SetNonblock and CloseOnExec.
    
    //go:build dragonfly || freebsd || linux || netbsd || openbsd
    
    package net
    
    import (
    	"os"
    	"syscall"
    )
    
    // Wrapper around the socket system call that marks the returned file
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Apr 14 18:17:25 UTC 2024
    - 730 bytes
    - Viewed (0)
  4. src/internal/poll/sock_cloexec.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    // This file implements accept for platforms that provide a fast path for
    // setting SetNonblock and CloseOnExec.
    
    //go:build dragonfly || freebsd || (linux && !arm) || netbsd || openbsd
    
    package poll
    
    import "syscall"
    
    // Wrapper around the accept system call that marks the returned file
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Apr 14 18:17:25 UTC 2024
    - 712 bytes
    - Viewed (0)
  5. src/internal/poll/fd_plan9.go

    	return errors.New("not implemented")
    }
    
    func DupCloseOnExec(fd int) (int, string, error) {
    	nfd, err := syscall.Dup(int(fd), -1)
    	if err != nil {
    		return 0, "dup", err
    	}
    	// Plan9 has no syscall.CloseOnExec but
    	// its forkAndExecInChild closes all fds
    	// not related to the fork+exec.
    	return nfd, "", nil
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon May 06 14:00:54 UTC 2024
    - 5.4K bytes
    - Viewed (0)
  6. src/os/removeall_at.go

    		if e == nil {
    			break
    		}
    
    		// See comment in openFileNolog.
    		if e == syscall.EINTR {
    			continue
    		}
    
    		return nil, e
    	}
    
    	if !supportsCloseOnExec {
    		syscall.CloseOnExec(r)
    	}
    
    	// We use kindNoPoll because we know that this is a directory.
    	return newFile(r, name, kindNoPoll, false), nil
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 11 17:09:26 UTC 2024
    - 4.8K bytes
    - Viewed (0)
  7. src/runtime/netpoll_kqueue.go

    )
    
    func netpollinit() {
    	kq = kqueue()
    	if kq < 0 {
    		println("runtime: kqueue failed with", -kq)
    		throw("runtime: netpollinit failed")
    	}
    	closeonexec(kq)
    	addWakeupEvent(kq)
    }
    
    func netpollopen(fd uintptr, pd *pollDesc) int32 {
    	// Arm both EVFILT_READ and EVFILT_WRITE in edge-triggered mode (EV_CLEAR)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Apr 12 21:17:22 UTC 2024
    - 4.6K bytes
    - Viewed (0)
  8. src/os/file_unix.go

    	if setSticky {
    		setStickyBit(name)
    	}
    
    	// There's a race here with fork/exec, which we are
    	// content to live with. See ../syscall/exec_unix.go.
    	if !supportsCloseOnExec {
    		syscall.CloseOnExec(r)
    	}
    
    	f := newFile(r, name, kindOpenFile, unix.HasNonblockFlag(flag))
    	f.pfd.SysFile = s
    	return f, nil
    }
    
    func openDirNolog(name string) (*File, error) {
    	var (
    		r int
    		s poll.SysFile
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 13:52:34 UTC 2024
    - 14.9K bytes
    - Viewed (0)
  9. src/syscall/fs_wasip1.go

    			fdflags,
    			unsafe.Pointer(&fd),
    		)
    	}
    	return int(fd), errnoErr(errno)
    }
    
    func Close(fd int) error {
    	errno := fd_close(int32(fd))
    	return errnoErr(errno)
    }
    
    func CloseOnExec(fd int) {
    	// nothing to do - no exec
    }
    
    func Mkdir(path string, perm uint32) error {
    	if path == "" {
    		return EINVAL
    	}
    	dirFd, pathPtr, pathLen := preparePath(path)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 15 19:57:43 UTC 2024
    - 24.1K bytes
    - Viewed (0)
  10. src/cmd/vendor/golang.org/x/sys/unix/syscall_zos_s390x.go

    	var fdx [2]int32
    	err = socketpair(domain, typ, proto, &fdx)
    	if err == nil {
    		fd[0] = int(fdx[0])
    		fd[1] = int(fdx[1])
    	}
    	return
    }
    
    var ioSync int64
    
    func CloseOnExec(fd int) { fcntl(fd, F_SETFD, FD_CLOEXEC) }
    
    func SetNonblock(fd int, nonblocking bool) (err error) {
    	flag, err := fcntl(fd, F_GETFL, 0)
    	if err != nil {
    		return err
    	}
    	if nonblocking {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 08 16:12:58 UTC 2024
    - 84.4K bytes
    - Viewed (0)
Back to top