fix(jobservice): value out of range (#14634)

value out of range when job count bigger than 256

Signed-off-by: vic <985695123@qq.com>
This commit is contained in:
Archer1A 2021-04-14 14:28:36 +08:00 committed by Steven Zou
parent b39bb0db63
commit e842042908

View File

@ -143,7 +143,7 @@ func (bm *basicManager) GetJobs(q *query.Parameter) ([]*job.Stats, int64, error)
return nil, 0, errors.New("malform scan results")
}
nextCur, err := strconv.ParseUint(string(values[0].([]byte)), 10, 8)
nextCur, err := strconv.ParseInt(string(values[0].([]byte)), 10, 64)
if err != nil {
return nil, 0, err
}
@ -166,7 +166,7 @@ func (bm *basicManager) GetJobs(q *query.Parameter) ([]*job.Stats, int64, error)
}
}
return results, int64(nextCur), nil
return results, nextCur, nil
}
// GetPeriodicExecution is implementation of Manager.GetPeriodicExecution