Add assertions to CustomElementReactionsStack::Enqueue to ensure upgrade reactions aren't scheduled to BackupQueue

RESOLVED FIXED in Firefox 58

Status

()

Core
DOM
P2
normal
RESOLVED FIXED
a year ago
6 months ago

People

(Reporter: edgar, Assigned: edgar)

Tracking

(Blocks: 1 bug)

unspecified
mozilla58
Points:
---

Firefox Tracking Flags

(firefox58 fixed)

Details

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

a year ago
+++ This bug was initially created as a follow-up of Bug #1299363 comment# 63 +++

After reviewing the all possible cases that may trigger upgrade steps in spec again (and also apply some local WIP patches to test),
- customElements.define: https://html.spec.whatwg.org/multipage/scripting.html#dom-customelementregistry-define
- document.createElement: https://dom.spec.whatwg.org/#dom-document-createelement
- document.createElementNS: https://dom.spec.whatwg.org/#dom-document-createelementns
- document.importNode: https://dom.spec.whatwg.org/#dom-document-importnode
- document.write: https://html.spec.whatwg.org/multipage/webappapis.html#dom-document-write
- document.writeln: https://html.spec.whatwg.org/multipage/webappapis.html#dom-document-writeln
- Element.innerHTML: https://w3c.github.io/DOM-Parsing/#dom-element-innerhtml
- Node.clone: https://dom.spec.whatwg.org/#concept-node-clone
- create element from parser: https://html.spec.whatwg.org/multipage/syntax.html#create-an-element-for-the-token

Most of API annotated with [CEReactions], excepts
- document.createElement[NS] runs upgrade steps synchronously, instead of interacting with reaction queue.
- parser bit has its own ReactionsStack push/pop.

So the upgrade reactions should not be scheduled to BackupQueue.

Updated

7 months ago
Priority: -- → P2
(Assignee)

Comment 2

6 months ago
Created attachment 8919225 [details] [diff] [review]
Patch, v1
(Assignee)

Updated

6 months ago
Attachment #8919311 - Flags: feedback?(jdai)

Updated

6 months ago
Attachment #8919311 - Flags: feedback?(jdai) → feedback+
(Assignee)

Updated

6 months ago
Attachment #8919311 - Flags: review?(bugs)

Updated

6 months ago
Attachment #8919311 - Flags: review?(bugs) → review+

Comment 4

6 months ago
Pushed by echen@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/96c6513a7f56
Add assertion to CustomElementReactionsStack::Enqueue to ensure upgrade reactions aren't scheduled to BackupQueue; r=smaug

Comment 5

6 months ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/96c6513a7f56
Status: NEW → RESOLVED
Last Resolved: 6 months ago
status-firefox58: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla58
You need to log in before you can comment on or make changes to this bug.