chore: cherry-pick 138b748dd0a4 from chromium #25232
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Update FocusChanged notifiers to operate on a copy
These focus changed calls ultimately trigger javascript events. These
events could potentially run code that would modify the list of items
that the FocusChanged notifiers are notifying, and thus invalidate their
in-use iterators.
Fix this by having these methods iterate over a copy instead of the
member list.
(cherry picked from commit d8f526f4e25c24ed29e60b46b3416bfabd5e8f11)
Fixed: 1107815
Change-Id: I03fa08eeadc60736f3a3fae079253dbd3ee26476
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2314158
Reviewed-by: Daniel Cheng dcheng@chromium.org
Reviewed-by: Klaus Weidner klausw@chromium.org
Commit-Queue: Daniel Cheng dcheng@chromium.org
Auto-Submit: Alexander Cooper alcooper@chromium.org
Cr-Original-Commit-Position: refs/heads/master@{#791261}
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2335893
Reviewed-by: Alexander Cooper alcooper@chromium.org
Commit-Queue: Alexander Cooper alcooper@chromium.org
Cr-Commit-Position: refs/branch-heads/4147@{#1015}
Cr-Branched-From: 16307825352720ae04d898f37efa5449ad68b606-refs/heads/master@{#768962}
Notes: Security: backported fix for 1107815.