Fixes problem where CPU goes to 100% when a job takes a long time.

Signed-off-by: Michel Verbraak <michel@1st-setup.nl>