Skip to content

Commit 6c036f2

Browse files
committed
pkg/sysinfo: rename max/min as it collides with go1.21 builtin
Signed-off-by: Sebastiaan van Stijn <[email protected]>
1 parent 55192de commit 6c036f2

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

pkg/sysinfo/sysinfo.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -151,13 +151,13 @@ func isCpusetListAvailable(provided, available string) (bool, error) {
151151
}
152152
// 8192 is the normal maximum number of CPUs in Linux, so accept numbers up to this
153153
// or more if we actually have more CPUs.
154-
max := 8192
154+
maxCPUs := 8192
155155
for m := range parsedAvailable {
156-
if m > max {
157-
max = m
156+
if m > maxCPUs {
157+
maxCPUs = m
158158
}
159159
}
160-
parsedProvided, err := parsers.ParseUintListMaximum(provided, max)
160+
parsedProvided, err := parsers.ParseUintListMaximum(provided, maxCPUs)
161161
if err != nil {
162162
return false, err
163163
}

0 commit comments

Comments
 (0)