mirror of
https://github.com/openfaas/faasd.git
synced 2025-06-22 14:53:30 +00:00
Upgrade containerd to 1.6.2 and CNI to 0.9.1
Upgrades containerd, and switches to the official 64-bit ARM binary. Continues to use my binary for 32-bit arm hosts. CNI upgraded to v0.9.1 Signed-off-by: Alex Ellis (OpenFaaS Ltd) <alexellis2@gmail.com>
This commit is contained in:
committed by
Alex Ellis
parent
449bcf2691
commit
912ac265f4
11
vendor/github.com/moby/sys/mountinfo/mounted_linux.go
generated
vendored
11
vendor/github.com/moby/sys/mountinfo/mounted_linux.go
generated
vendored
@ -16,9 +16,6 @@ func mountedByOpenat2(path string) (bool, error) {
|
||||
Flags: unix.O_PATH | unix.O_CLOEXEC,
|
||||
})
|
||||
if err != nil {
|
||||
if err == unix.ENOENT { // not a mount
|
||||
return false, nil
|
||||
}
|
||||
return false, &os.PathError{Op: "openat2", Path: dir, Err: err}
|
||||
}
|
||||
fd, err := unix.Openat2(dirfd, last, &unix.OpenHow{
|
||||
@ -26,20 +23,22 @@ func mountedByOpenat2(path string) (bool, error) {
|
||||
Resolve: unix.RESOLVE_NO_XDEV,
|
||||
})
|
||||
_ = unix.Close(dirfd)
|
||||
switch err {
|
||||
switch err { //nolint:errorlint // unix errors are bare
|
||||
case nil: // definitely not a mount
|
||||
_ = unix.Close(fd)
|
||||
return false, nil
|
||||
case unix.EXDEV: // definitely a mount
|
||||
return true, nil
|
||||
case unix.ENOENT: // not a mount
|
||||
return false, nil
|
||||
}
|
||||
// not sure
|
||||
return false, &os.PathError{Op: "openat2", Path: path, Err: err}
|
||||
}
|
||||
|
||||
func mounted(path string) (bool, error) {
|
||||
path, err := normalizePath(path)
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
// Try a fast path, using openat2() with RESOLVE_NO_XDEV.
|
||||
mounted, err := mountedByOpenat2(path)
|
||||
if err == nil {
|
||||
|
Reference in New Issue
Block a user