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.