Does not stay in an endless loop when a process fails with an error.