Skip to content

Commit

Permalink
Merge pull request weaveworks#860 from sc68cal/main
Browse files Browse the repository at this point in the history
Cast to uint64 for Darwin platform
  • Loading branch information
darkowlzz authored Aug 9, 2021
2 parents d64c3f3 + 6c509b1 commit ca96ad4
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pkg/runtime/containerd/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -630,8 +630,9 @@ func withDevices(devices []*runtime.Bind) oci.SpecOpts {
return err
}

major := int64(unix.Major(stat.Rdev))
minor := int64(unix.Minor(stat.Rdev))
// Cast up to uint64 from stat strut on other OS's
major := int64(unix.Major(uint64(stat.Rdev)))
minor := int64(unix.Minor(uint64(stat.Rdev)))

s.Linux.Resources.Devices = append(s.Linux.Resources.Devices, specs.LinuxDeviceCgroup{
Type: devType,
Expand Down

0 comments on commit ca96ad4

Please sign in to comment.