Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(42)

Issue 1532103002: Better handling of DocumentOrderedMap same-ID lookups during tree removals (Closed)

Created:
5 years ago by sof
Modified:
5 years ago
Reviewers:
tkent, esprehn
CC:
blink-reviews, blink-reviews-dom_chromium.org, chromium-reviews, dglazkov+blink, eae+blinkwatch, rwlbuis
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Better handling of DocumentOrderedMap same-ID lookups during tree removals Under select and unusal conditions, the removal of an element with ID A might trigger further lookups of A from a TreeScope's DocumentOrderedMap as part of handling the removal of that element. The tree and DocumentOrderedMap is not in a consistent state to precisely handle such lookups -- add machinery to spot that we're in a transitory state and not trigger an assert over such failing lookups. See code comments for further details. R=tkent,esprehn BUG=426005 Committed: https://crrev.com/c7a51bc56703af56f1c227fc8452913d86a840bc Cr-Commit-Position: refs/heads/master@{#366066}

Patch Set 1 #

Patch Set 2 : tweak comment #

Patch Set 3 : spelling #

Total comments: 16

Patch Set 4 : review updates #

Patch Set 5 : review updates, part2 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+84 lines, -16 lines) Patch
A + third_party/WebKit/LayoutTests/fast/forms/form-associated-element-crash5.html View 1 chunk +8 lines, -9 lines 0 comments Download
A + third_party/WebKit/LayoutTests/fast/forms/form-associated-element-crash5-expected.txt View 0 chunks +-1 lines, --1 lines 0 comments Download
M third_party/WebKit/Source/core/dom/DocumentOrderedMap.h View 1 2 3 3 chunks +12 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/dom/DocumentOrderedMap.cpp View 1 2 3 4 4 chunks +32 lines, -7 lines 0 comments Download
M third_party/WebKit/Source/core/dom/TreeScope.cpp View 1 2 3 4 1 chunk +33 lines, -0 lines 0 comments Download

Messages

Total messages: 17 (7 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1532103002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1532103002/1
5 years ago (2015-12-17 14:28:06 UTC) #2
sof
Please take a look. Ripping out the assert considered as hiding too many unexpected failures, ...
5 years ago (2015-12-17 15:45:41 UTC) #4
tkent
lgtm https://codereview.chromium.org/1532103002/diff/40001/third_party/WebKit/Source/core/dom/DocumentOrderedMap.h File third_party/WebKit/Source/core/dom/DocumentOrderedMap.h (right): https://codereview.chromium.org/1532103002/diff/40001/third_party/WebKit/Source/core/dom/DocumentOrderedMap.h#newcode94 third_party/WebKit/Source/core/dom/DocumentOrderedMap.h:94: const AtomicString* m_removingId; Can you make this |AtomicString| ...
5 years ago (2015-12-18 00:30:57 UTC) #5
esprehn
This seems bad, we're covering up that we do an entire tree walk looking for ...
5 years ago (2015-12-18 00:42:26 UTC) #6
sof
On 2015/12/18 00:42:26, esprehn wrote: > This seems bad, we're covering up that we do ...
5 years ago (2015-12-18 06:20:01 UTC) #7
sof
https://codereview.chromium.org/1532103002/diff/40001/third_party/WebKit/Source/core/dom/DocumentOrderedMap.cpp File third_party/WebKit/Source/core/dom/DocumentOrderedMap.cpp (right): https://codereview.chromium.org/1532103002/diff/40001/third_party/WebKit/Source/core/dom/DocumentOrderedMap.cpp#newcode146 third_party/WebKit/Source/core/dom/DocumentOrderedMap.cpp:146: // register the element ID it is in the ...
5 years ago (2015-12-18 07:31:53 UTC) #8
esprehn
lgtm https://codereview.chromium.org/1532103002/diff/40001/third_party/WebKit/Source/core/dom/TreeScope.cpp File third_party/WebKit/Source/core/dom/TreeScope.cpp (right): https://codereview.chromium.org/1532103002/diff/40001/third_party/WebKit/Source/core/dom/TreeScope.cpp#newcode199 third_party/WebKit/Source/core/dom/TreeScope.cpp:199: m_elementsById->willBeRemovingId(&id); On 2015/12/18 at 07:31:53, sof wrote: > ...
5 years ago (2015-12-18 07:53:40 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1532103002/70001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1532103002/70001
5 years ago (2015-12-18 08:08:44 UTC) #13
commit-bot: I haz the power
Committed patchset #5 (id:70001)
5 years ago (2015-12-18 09:34:01 UTC) #15
commit-bot: I haz the power
5 years ago (2015-12-18 09:35:20 UTC) #17
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/c7a51bc56703af56f1c227fc8452913d86a840bc
Cr-Commit-Position: refs/heads/master@{#366066}

Powered by Google App Engine
This is Rietveld 408576698