fix(dashboard): proper check uint32 size (#113760)
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
"context"
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"math"
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
@@ -1726,7 +1727,7 @@ func buildAnnotationFilter(filterMap map[string]interface{}) *dashv2alpha1.Dashb
|
||||
uintIds = append(uintIds, uint32(v))
|
||||
}
|
||||
case int:
|
||||
if v >= 0 && v <= int(^uint32(0)) {
|
||||
if v >= 0 && v <= math.MaxUint32 {
|
||||
uintIds = append(uintIds, uint32(v))
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user