harden job limit enforcement

There should be no change in behavior with the production code,
but this will improve the robustness of the code if someone makes
changes to the logic.
Merge branch 'slurm-14.03'