| Summary: | [WPT] dom/nodes/Document-createCDATASection-xhtml.xhtml fails due to missing exception in Document.createCDATASection() | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Sam Weinig <sam> | ||||||
| Component: | DOM | Assignee: | Sam Weinig <sam> | ||||||
| Status: | RESOLVED FIXED | ||||||||
| Severity: | Normal | CC: | cdumez, darin, esprehn+autocc, ews-watchlist, kangil.han, rniwa, webkit-bug-importer, ysuzuki | ||||||
| Priority: | P2 | Keywords: | InRadar | ||||||
| Version: | WebKit Nightly Build | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Attachments: |
|
||||||||
|
Description
Sam Weinig
2020-06-13 09:47:26 PDT
Created attachment 401841 [details]
Patch
Comment on attachment 401841 [details]
Patch
r=me
Created attachment 401843 [details]
Patch
Committed r263003: <https://trac.webkit.org/changeset/263003> All reviewed patches have been landed. Closing bug and clearing flags on attachment 401843 [details]. Comment on attachment 401843 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=401843&action=review > Source/WebCore/dom/Document.cpp:1031 > + if (data.contains("]]>")) Does cdatasection::create not need the check? Performance implications seem non-trivial here. (In reply to Alexey Proskuryakov from comment #7) > Comment on attachment 401843 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=401843&action=review > > > Source/WebCore/dom/Document.cpp:1031 > > + if (data.contains("]]>")) > > Does cdatasection::create not need the check? I don't believe it does. The only other caller of CDATASection::create (other than right after this check) is XMLDocumentParser::cdataBlock, and I don't think the parser can get into this issue. > > Performance implications seem non-trivial here. Really? I don't think of something like document.createCDATASection() getting called all that much from the DOM. We now match the other major browsers and the spec, so it does turn out to a perf issue, we should also raise it with the standards folks. (In reply to Sam Weinig from comment #8) > (In reply to Alexey Proskuryakov from comment #7) > > Comment on attachment 401843 [details] > > Patch > > > > View in context: > > https://bugs.webkit.org/attachment.cgi?id=401843&action=review > > > > > Source/WebCore/dom/Document.cpp:1031 > > > + if (data.contains("]]>")) > > > > Does cdatasection::create not need the check? > > I don't believe it does. The only other caller of CDATASection::create > (other than right after this check) is XMLDocumentParser::cdataBlock, and I > don't think the parser can get into this issue. > > > > > Performance implications seem non-trivial here. > > Really? I don't think of something like document.createCDATASection() > getting called all that much from the DOM. We now match the other major > browsers and the spec, so it does turn out to a perf issue, we should also > raise it with the standards folks. I agree with Sam here. |