When running multiple threads, one thread could clear allocationsForDownload while another was iterating over it. Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>