fix: possible nil deref in admin_info (#3500)
This commit is contained in:
@@ -1121,12 +1121,13 @@ LabelsWaitLoop:
|
||||
if inStep != nil && *inStep > 0 {
|
||||
step = *inStep
|
||||
}
|
||||
if step > 0 {
|
||||
extraParamters = fmt.Sprintf("%s&step=%d", extraParamters, step)
|
||||
}
|
||||
|
||||
if inStart != nil && inEnd != nil {
|
||||
extraParamters = fmt.Sprintf("&start=%d&end=%d&step=%d", *inStart, *inEnd, *inStep)
|
||||
extraParamters = fmt.Sprintf("&start=%d&end=%d", *inStart, *inEnd)
|
||||
}
|
||||
|
||||
if step > 0 {
|
||||
extraParamters = fmt.Sprintf("%s&step=%d", extraParamters, step)
|
||||
}
|
||||
|
||||
// replace the `$__rate_interval` global for step with unit (s for seconds)
|
||||
|
||||
Reference in New Issue
Block a user