Since the sResourcesHistory set is synchronized, an attemp to modify the
set will block while the forEach() method is running in the rare case
resources are being dumped. With a normal for loop, modifying the set
while in the loop results in a ConcurrentModificationException.
Fixes: 219609463
Test: Manual
Change-Id: I9b7bb965aa390e5dec696be07599f777c807c1e3