job_coordinator: fix the return value of retry_task in case of failure

This will fix the error messages when there are many task failures. Now the
erorr message clearly shows that the reason the job failed is because a single
task had many failures.
Merge pull request #572 from pooya/571

job_coordinator: fix the return value of retry_task in case of failure