Added synchronized when iterating over synchronizedList as per Java specification
This commit is contained in:
parent
a0249da8a7
commit
3c6c1d973c
|
@ -836,10 +836,12 @@ public class NNStorage extends Storage implements Closeable,
|
|||
* @param sds A list of storage directories to mark as errored.
|
||||
*/
|
||||
void reportErrorsOnDirectories(List<StorageDirectory> sds) {
|
||||
synchronized(sds) {
|
||||
for (StorageDirectory sd : sds) {
|
||||
reportErrorsOnDirectory(sd);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Reports that a directory has experienced an error.
|
||||
|
|
Loading…
Reference in New Issue