Fix regression from ag/2987716

- Removing some tasks can trigger the list to be updated (for the removed
  task), ensure that we iterate the list backwards so that iteration is
  not affected by any removed tasks.

Bug: 67785147
Test: Just reverting some code

Change-Id: If8afc222f62656cbf5404bcf79c70833514103e7
Signed-off-by: Winson Chung <winsonc@google.com>
1 file changed