Task scheduling improvement

Now the next time that the task will execute doesn't have the accumulated
time of the execution of the task itself.