Use int as priority value type.

Do not use unsigned int for merely non-negative quantities as it
complicates simple arithmetic.
This commit is contained in:
Ken Hibino
2020-02-12 22:23:25 -08:00
parent bf31fcc3ec
commit d33ca98648
15 changed files with 84 additions and 70 deletions

View File

@@ -23,7 +23,7 @@ type scheduler struct {
qnames []string
}
func newScheduler(r *rdb.RDB, avgInterval time.Duration, qcfg map[string]uint) *scheduler {
func newScheduler(r *rdb.RDB, avgInterval time.Duration, qcfg map[string]int) *scheduler {
var qnames []string
for q := range qcfg {
qnames = append(qnames, q)