vendor: opencontainers/runc v1.0.0-rc91-48-g67169a9d

full diff: https://github.com/opencontainers/runc/compare/v1.0.0-rc91...67169a9d43456ff0d5ae12b967acb8e366e2f181

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn
2020-08-05 15:36:19 +02:00
parent 78e5277419
commit fd030873ac
8 changed files with 38 additions and 19 deletions

View File

@@ -37,12 +37,12 @@ func DeviceFromPath(path, permissions string) (*configs.Device, error) {
major = unix.Major(devNumber)
minor = unix.Minor(devNumber)
)
switch {
case mode&unix.S_IFBLK == unix.S_IFBLK:
switch mode & unix.S_IFMT {
case unix.S_IFBLK:
devType = configs.BlockDevice
case mode&unix.S_IFCHR == unix.S_IFCHR:
case unix.S_IFCHR:
devType = configs.CharDevice
case mode&unix.S_IFIFO == unix.S_IFIFO:
case unix.S_IFIFO:
devType = configs.FifoDevice
default:
return nil, ErrNotADevice
@@ -104,6 +104,9 @@ func GetDevices(path string) ([]*configs.Device, error) {
}
return nil, err
}
if device.Type == configs.FifoDevice {
continue
}
out = append(out, device)
}
return out, nil