vendor runc library to v1.0.0-rc91-48-g67169a9d
Signed-off-by: Jintao Zhang <zhangjintao9020@gmail.com>
This commit is contained in:
16
vendor/github.com/opencontainers/runc/libcontainer/configs/device_unix.go
generated
vendored
Normal file
16
vendor/github.com/opencontainers/runc/libcontainer/configs/device_unix.go
generated
vendored
Normal file
@@ -0,0 +1,16 @@
|
||||
// +build !windows
|
||||
|
||||
package configs
|
||||
|
||||
import (
|
||||
"errors"
|
||||
|
||||
"golang.org/x/sys/unix"
|
||||
)
|
||||
|
||||
func (d *DeviceRule) Mkdev() (uint64, error) {
|
||||
if d.Major == Wildcard || d.Minor == Wildcard {
|
||||
return 0, errors.New("cannot mkdev() device with wildcards")
|
||||
}
|
||||
return unix.Mkdev(uint32(d.Major), uint32(d.Minor)), nil
|
||||
}
|
||||
Reference in New Issue
Block a user