...

Source file src/github.com/opencontainers/runc/libcontainer/eaccess_go119.go

Documentation: github.com/opencontainers/runc/libcontainer

     1  //go:build !go1.20
     2  // +build !go1.20
     3  
     4  package libcontainer
     5  
     6  import "golang.org/x/sys/unix"
     7  
     8  func eaccess(path string) error {
     9  	// This check is similar to access(2) with X_OK except for
    10  	// setuid/setgid binaries where it checks against the effective
    11  	// (rather than real) uid and gid. It is not needed in go 1.20
    12  	// and beyond and will be removed later.
    13  
    14  	// Relies on code added in https://go-review.googlesource.com/c/sys/+/468877
    15  	// and older CLs linked from there.
    16  	return unix.Faccessat(unix.AT_FDCWD, path, unix.X_OK, unix.AT_EACCESS)
    17  }
    18  

View as plain text