Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(67)

Unified Diff: third_party/WebKit/Source/core/css/CSSStyleRule.cpp

Issue 1616423003: Fix selector namespace prefix resolution. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Corrected correction Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/css/CSSStyleRule.cpp
diff --git a/third_party/WebKit/Source/core/css/CSSStyleRule.cpp b/third_party/WebKit/Source/core/css/CSSStyleRule.cpp
index 1b9d4fb640b95e111981dbe01eb0f94a922f065c..a8afa823a5b7e3c25f42f931a0dffbe02b28c366 100644
--- a/third_party/WebKit/Source/core/css/CSSStyleRule.cpp
+++ b/third_party/WebKit/Source/core/css/CSSStyleRule.cpp
@@ -95,7 +95,7 @@ String CSSStyleRule::selectorText() const
void CSSStyleRule::setSelectorText(const String& selectorText)
{
CSSParserContext context(parserContext(), 0);
- CSSSelectorList selectorList = CSSParser::parseSelector(context, selectorText);
+ CSSSelectorList selectorList = CSSParser::parseSelector(context, parentStyleSheet()->contents(), selectorText);
Timothy Loh 2016/01/25 00:30:47 You probably need to null-check parentStyleSheet (
rune 2016/01/25 08:58:48 Done.
if (!selectorList.isValid())
return;

Powered by Google App Engine
This is Rietveld 408576698