Bug 49700 - XSLTProcessor.importNode is only tested with document nodes, and hits an assertion
Summary: XSLTProcessor.importNode is only tested with document nodes, and hits an asse...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: XML (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Alexey Proskuryakov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-17 17:09 PST by Alexey Proskuryakov
Modified: 2010-11-18 10:32 PST (History)
3 users (show)

See Also:


Attachments
proposed fix (6.27 KB, patch)
2010-11-17 17:12 PST, Alexey Proskuryakov
darin: review+
Details | Formatted Diff | Diff
patch for landing (6.63 KB, patch)
2010-11-18 00:57 PST, Alexey Proskuryakov
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexey Proskuryakov 2010-11-17 17:09:31 PST
The assertion I added to StyleSheet constructor was wrong.
Comment 1 Alexey Proskuryakov 2010-11-17 17:12:07 PST
Created attachment 74181 [details]
proposed fix
Comment 2 WebKit Review Bot 2010-11-17 17:13:55 PST
Attachment 74181 [details] did not pass style-queue:

Failed to run "['WebKitTools/Scripts/check-webkit-style', '--diff-files', u'LayoutTests/ChangeLog', u'LayoutTests/fast/xsl/import-non-document-node-expected.txt', u'LayoutTests/fast/xsl/import-non-document-node.xhtml', u'WebCore/ChangeLog', u'WebCore/css/CSSStyleSheet.cpp', u'WebCore/css/StyleSheet.cpp']" exit_code: 1
WebCore/css/CSSStyleSheet.cpp:51:  Line contains only semicolon. If this should be an empty statement, use { } instead.  [whitespace/semicolon] [5]
Total errors found: 1 in 5 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Darin Adler 2010-11-17 22:50:33 PST
Comment on attachment 74181 [details]
proposed fix

View in context: https://bugs.webkit.org/attachment.cgi?id=74181&action=review

> WebCore/css/CSSStyleSheet.cpp:50
> +#if ENABLE(SVG)
> +        || parentNode->hasTagName(SVGNames::styleTag)
> +#endif    

If you moved this expression up one line so it was next to the HTML style tag, then you could use a more-normal semicolon-on-end-of-line.
Comment 4 Alexey Proskuryakov 2010-11-18 00:57:41 PST
Created attachment 74214 [details]
patch for landing
Comment 5 Alexey Proskuryakov 2010-11-18 09:45:05 PST
Comment on attachment 74214 [details]
patch for landing

Commit-queue ignored this, landing manually.
Comment 6 Alexey Proskuryakov 2010-11-18 09:49:21 PST
Committed <http://trac.webkit.org/changeset/72301>.
Comment 7 WebKit Review Bot 2010-11-18 10:25:32 PST
http://trac.webkit.org/changeset/72301 might have broken Qt Linux Release
The following tests are not passing:
fast/xsl/import-non-document-node.xhtml
Comment 8 Alexey Proskuryakov 2010-11-18 10:32:25 PST
Disabled the test for Qt in <http://trac.webkit.org/changeset/72308>, filed bug 49743.