fixed job allocation bug.