Various places don't deal with non-constructed adopted stylesheets properly
Categories
(Core :: DOM: CSS Object Model, defect, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox-esr128 | --- | unaffected |
firefox135 | --- | unaffected |
firefox136 | --- | affected |
firefox137 | --- | affected |
People
(Reporter: emilio, Unassigned, NeedInfo)
References
(Regression)
Details
(Keywords: regression)
Various places assume that if a sheet is not constructed, it can't appear in mAdoptedStyleSheets:
https://searchfox.org/mozilla-central/rev/b1662b447f306e6554647914090d4b73ac8e1664/dom/base/DocumentOrShadowRoot.cpp#631
https://searchfox.org/mozilla-central/rev/b1662b447f306e6554647914090d4b73ac8e1664/dom/base/ShadowRoot.cpp#527
https://searchfox.org/mozilla-central/rev/b1662b447f306e6554647914090d4b73ac8e1664/layout/style/StyleSheet.cpp#182,187-193 assumes that if the sheet is constructed, its document matches the adopter which was also lifted.
I'm not convinced we want to open the can of cross-document adoption, fwiw. Maybe it's worth putting that restriction back in place at least.
Reporter | ||
Updated•10 days ago
|
Reporter | ||
Comment 1•10 days ago
|
||
Should also probably prevent @import
sheets from being adopted, or otherwise that's another whole can of worms.
Comment 2•10 days ago
|
||
:mozilla, since you are the author of the regressor, bug 1944244, could you take a look?
For more information, please visit BugBot documentation.
Comment 3•9 days ago
|
||
Set release status flags based on info from the regressing bug 1944244
Description
•