commit | 4854c717b85694e4902dbb3bc4c1abd9081ec722 | [log] [tgz] |
---|---|---|
author | paulhu <paulhu@google.com> | Mon Jul 20 18:12:00 2020 +0800 |
committer | Paul Hu <paulhu@google.com> | Tue Jul 21 07:34:44 2020 +0000 |
tree | ebcc5b1a46f79e6e264303c2b97bbb2e0a131126 | |
parent | 2b0d80469fa72f35a080186692f1a029e80dc885 [diff] |
Replace ArrayList with a CopyOnWriteArrayList RegularMaintenanceJobService use same ArrayList on both omComplete and onStopJob methods, it's unsafe and will cause ConcurrentModificationException when reading and removing value at same time. Thus, replace ArrayList with a CopyOnWriteArrayList. Bug: 161205152 Test: atest NetworkStackTests Change-Id: I3914e9ddc05e37d4deaa8846d7c3ba742160a788