mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-09-02 15:37:11 +00:00
correctly handle fields in cmdline for cgroupsv2
Signed-off-by: Avi Deitcher <avi@deitcher.net>
This commit is contained in:
@@ -429,7 +429,7 @@ func isCgroupV2() bool {
|
||||
log.Printf("error reading /proc/cmdline: %v", err)
|
||||
return false
|
||||
}
|
||||
for _, s := range strings.Split(string(dt), " ") {
|
||||
for _, s := range strings.Fields(string(dt)) {
|
||||
if s == "linuxkit.unified_cgroup_hierarchy=1" {
|
||||
return true
|
||||
}
|
||||
|
Reference in New Issue
Block a user