diff --git a/src/runtime/pkg/resourcecontrol/utils_linux.go b/src/runtime/pkg/resourcecontrol/utils_linux.go index 59ca788f81..0acbc6c6af 100644 --- a/src/runtime/pkg/resourcecontrol/utils_linux.go +++ b/src/runtime/pkg/resourcecontrol/utils_linux.go @@ -156,7 +156,7 @@ func IsCgroupV1() (bool, error) { func SetThreadAffinity(threadID int, cpuSetSlice []int) error { unixCPUSet := unix.CPUSet{} - for cpuId := range cpuSetSlice { + for _, cpuId := range cpuSetSlice { unixCPUSet.Set(cpuId) }