Title: [289893] releases/WebKitGTK/webkit-2.34
- Revision
- 289893
- Author
- ape...@igalia.com
- Date
- 2022-02-16 09:16:03 -0800 (Wed, 16 Feb 2022)
Log Message
Merge r289526 - [:has() pseudo-class] Nullptr crash with non-function :has
https://bugs.webkit.org/show_bug.cgi?id=236431
rdar://87061239
Reviewed by Cameron McCormack.
LayoutTests/imported/w3c:
* web-platform-tests/css/selectors/parsing/parse-has-expected.txt:
* web-platform-tests/css/selectors/parsing/parse-has.html:
Source/WebCore:
Test: fast/selectors/malformed-has.html
* css/parser/CSSSelectorParser.cpp:
(WebCore::isOnlyPseudoClassFunction):
:has() is legal, plain :has is not.
LayoutTests:
* fast/selectors/malformed-has-expected.txt: Added.
* fast/selectors/malformed-has.html: Added.
Modified Paths
Added Paths
Diff
Modified: releases/WebKitGTK/webkit-2.34/LayoutTests/ChangeLog (289892 => 289893)
--- releases/WebKitGTK/webkit-2.34/LayoutTests/ChangeLog 2022-02-16 16:58:48 UTC (rev 289892)
+++ releases/WebKitGTK/webkit-2.34/LayoutTests/ChangeLog 2022-02-16 17:16:03 UTC (rev 289893)
@@ -1,3 +1,14 @@
+2022-02-10 Antti Koivisto <an...@apple.com>
+
+ [:has() pseudo-class] Nullptr crash with non-function :has
+ https://bugs.webkit.org/show_bug.cgi?id=236431
+ rdar://87061239
+
+ Reviewed by Cameron McCormack.
+
+ * fast/selectors/malformed-has-expected.txt: Added.
+ * fast/selectors/malformed-has.html: Added.
+
2022-02-03 Frédéric Wang <fw...@igalia.com>
null ptr deref in RenderTreeBuilder::Block::attachIgnoringContinuation
Added: releases/WebKitGTK/webkit-2.34/LayoutTests/fast/selectors/malformed-has-expected.txt (0 => 289893)
--- releases/WebKitGTK/webkit-2.34/LayoutTests/fast/selectors/malformed-has-expected.txt (rev 0)
+++ releases/WebKitGTK/webkit-2.34/LayoutTests/fast/selectors/malformed-has-expected.txt 2022-02-16 17:16:03 UTC (rev 289893)
@@ -0,0 +1 @@
+This test passes if it doesn't crash.
Added: releases/WebKitGTK/webkit-2.34/LayoutTests/fast/selectors/malformed-has.html (0 => 289893)
--- releases/WebKitGTK/webkit-2.34/LayoutTests/fast/selectors/malformed-has.html (rev 0)
+++ releases/WebKitGTK/webkit-2.34/LayoutTests/fast/selectors/malformed-has.html 2022-02-16 17:16:03 UTC (rev 289893)
@@ -0,0 +1,9 @@
+<style>
+div:has { color: red; }
+</style>
+<div>This test passes if it doesn't crash.</div>
+
+<script>
+if (window.testRunner)
+ testRunner.dumpAsText();
+</script>
Modified: releases/WebKitGTK/webkit-2.34/LayoutTests/imported/w3c/ChangeLog (289892 => 289893)
--- releases/WebKitGTK/webkit-2.34/LayoutTests/imported/w3c/ChangeLog 2022-02-16 16:58:48 UTC (rev 289892)
+++ releases/WebKitGTK/webkit-2.34/LayoutTests/imported/w3c/ChangeLog 2022-02-16 17:16:03 UTC (rev 289893)
@@ -1,3 +1,14 @@
+2022-02-10 Antti Koivisto <an...@apple.com>
+
+ [:has() pseudo-class] Nullptr crash with non-function :has
+ https://bugs.webkit.org/show_bug.cgi?id=236431
+ rdar://87061239
+
+ Reviewed by Cameron McCormack.
+
+ * web-platform-tests/css/selectors/parsing/parse-has-expected.txt:
+ * web-platform-tests/css/selectors/parsing/parse-has.html:
+
2022-01-25 Alexey Shvayka <ashva...@apple.com>
XPath::Step::nodesInAxis(): add null checks after Attr::ownerElement() calls
Modified: releases/WebKitGTK/webkit-2.34/LayoutTests/imported/w3c/web-platform-tests/css/selectors/parsing/parse-has-expected.txt (289892 => 289893)
--- releases/WebKitGTK/webkit-2.34/LayoutTests/imported/w3c/web-platform-tests/css/selectors/parsing/parse-has-expected.txt 2022-02-16 16:58:48 UTC (rev 289892)
+++ releases/WebKitGTK/webkit-2.34/LayoutTests/imported/w3c/web-platform-tests/css/selectors/parsing/parse-has-expected.txt 2022-02-16 17:16:03 UTC (rev 289893)
@@ -38,4 +38,7 @@
PASS "*|*:has(*)" should be a valid selector
PASS ":has(*|*)" should be a valid selector
PASS ".a:has()" should be an invalid selector
+PASS ":has" should be an invalid selector
+PASS ".a:has" should be an invalid selector
+PASS ".a:has b" should be an invalid selector
Modified: releases/WebKitGTK/webkit-2.34/LayoutTests/imported/w3c/web-platform-tests/css/selectors/parsing/parse-has.html (289892 => 289893)
--- releases/WebKitGTK/webkit-2.34/LayoutTests/imported/w3c/web-platform-tests/css/selectors/parsing/parse-has.html 2022-02-16 16:58:48 UTC (rev 289892)
+++ releases/WebKitGTK/webkit-2.34/LayoutTests/imported/w3c/web-platform-tests/css/selectors/parsing/parse-has.html 2022-02-16 17:16:03 UTC (rev 289893)
@@ -46,4 +46,7 @@
test_valid_selector('*|*:has(*)', ':has(*)');
test_valid_selector(':has(*|*)', ':has(*)');
test_invalid_selector('.a:has()');
-</script>
\ No newline at end of file
+ test_invalid_selector(':has');
+ test_invalid_selector('.a:has');
+ test_invalid_selector('.a:has b');
+</script>
Modified: releases/WebKitGTK/webkit-2.34/Source/WebCore/ChangeLog (289892 => 289893)
--- releases/WebKitGTK/webkit-2.34/Source/WebCore/ChangeLog 2022-02-16 16:58:48 UTC (rev 289892)
+++ releases/WebKitGTK/webkit-2.34/Source/WebCore/ChangeLog 2022-02-16 17:16:03 UTC (rev 289893)
@@ -1,3 +1,18 @@
+2022-02-10 Antti Koivisto <an...@apple.com>
+
+ [:has() pseudo-class] Nullptr crash with non-function :has
+ https://bugs.webkit.org/show_bug.cgi?id=236431
+ rdar://87061239
+
+ Reviewed by Cameron McCormack.
+
+ Test: fast/selectors/malformed-has.html
+
+ * css/parser/CSSSelectorParser.cpp:
+ (WebCore::isOnlyPseudoClassFunction):
+
+ :has() is legal, plain :has is not.
+
2022-02-11 Michael Catanzaro <mcatanz...@gnome.org>
[GTK] WebKit browser scrollbars not always correctly displayed if overlay scrollbars are disabled
Modified: releases/WebKitGTK/webkit-2.34/Source/WebCore/css/parser/CSSSelectorParser.cpp (289892 => 289893)
--- releases/WebKitGTK/webkit-2.34/Source/WebCore/css/parser/CSSSelectorParser.cpp 2022-02-16 16:58:48 UTC (rev 289892)
+++ releases/WebKitGTK/webkit-2.34/Source/WebCore/css/parser/CSSSelectorParser.cpp 2022-02-16 17:16:03 UTC (rev 289893)
@@ -582,6 +582,7 @@
case CSSSelector::PseudoClassIs:
case CSSSelector::PseudoClassMatches:
case CSSSelector::PseudoClassWhere:
+ case CSSSelector::PseudoClassHas:
case CSSSelector::PseudoClassNthChild:
case CSSSelector::PseudoClassNthLastChild:
case CSSSelector::PseudoClassNthOfType:
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes