diff options
| author | 2024-01-04 10:23:45 -0500 | |
|---|---|---|
| committer | 2024-01-04 11:16:07 -0500 | |
| commit | bd698f156352aab2713381ffb78b8b5ce7d3444c (patch) | |
| tree | 95fbd7e6d6611166404621b78eb0aaee97038b94 /libs/androidfw/StringPool.cpp | |
| parent | 77c5fef85b271c80da36dc24e92291934f01c3b8 (diff) | |
Prevent ConcurrentModificationException
While dispatching a change to callbacks, if one of them removes itself
as part of the operation, it would cause a
ConcurrentModificationException (because it's in the same thread, so
it's re-entrant).
Prevent this by copying the list before dispatching.
Test: atest CastControllerImplTest
Fixes: 317700495
Flag: None
Change-Id: I8fed9957dd167437f3c3e9bde3ccbb48b0b4f6c3
Diffstat (limited to 'libs/androidfw/StringPool.cpp')
0 files changed, 0 insertions, 0 deletions