mirror of
https://github.com/containers/podman.git
synced 2025-12-04 04:09:40 +08:00
vendor: update c/common
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
14
vendor/github.com/opencontainers/cgroups/devices/config/mknod_unix.go
generated
vendored
Normal file
14
vendor/github.com/opencontainers/cgroups/devices/config/mknod_unix.go
generated
vendored
Normal file
@@ -0,0 +1,14 @@
|
||||
package config
|
||||
|
||||
import (
|
||||
"errors"
|
||||
|
||||
"golang.org/x/sys/unix"
|
||||
)
|
||||
|
||||
func mkDev(d *Rule) (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