summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-11-28 07:40:40 +0100
committerAndreas Kling <awesomekling@gmail.com>2019-11-28 14:48:51 +0100
commitf0c94758f48598a6f3055ae48988397310d45a1d (patch)
treec56ffb4a1a09593dbc4688112197ea5288b8d477
parenta42e4770026800c31f938dd9b5f8ffd4c5e143ac (diff)
downloadserenity-f0c94758f48598a6f3055ae48988397310d45a1d.zip
LibHTML: CSS parser should accept "foo>bar", not just "foo > bar"
If we peek a combinator at the start of a simple selector, we're seeing the start of a new complex selector.
-rw-r--r--Libraries/LibHTML/Parser/CSSParser.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Libraries/LibHTML/Parser/CSSParser.cpp b/Libraries/LibHTML/Parser/CSSParser.cpp
index 33c32619a8..de20713ca7 100644
--- a/Libraries/LibHTML/Parser/CSSParser.cpp
+++ b/Libraries/LibHTML/Parser/CSSParser.cpp
@@ -207,7 +207,7 @@ public:
if (consume_whitespace_or_comments())
return {};
- if (peek() == '{' || peek() == ',')
+ if (peek() == '{' || peek() == ',' || is_combinator(peek()))
return {};
Selector::SimpleSelector::Type type;