Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mxqd: Fix checks for group_jobs and jobs_max
After commit e6ef2ad ("Move server_is_qualified() to mxqd_control") the result of the qualification checks (blacklist, whitelist, prerequisites, exclusive mode) are no longer stored as a boolean in glist->server_is_qualified. Instead, glist->jobs_max is set to 0 if the server is not qualified to start a job from the group. However, there is a bug in start_user: if (glist->jobs_running == group->group_jobs) { continue; } if (glist->jobs_running == glist->jobs_max) { continue; } The number of jobs running may actually be higher then the current limits, if limits are decreased while jobs are already running. This not only applies to changes cause by mxqset, but also to a server restart with different limits. Change comparisons from equality to greater than or equal.
- Loading branch information