Index: third_party/WebKit/Source/core/css/StylePropertySet.cpp |
diff --git a/third_party/WebKit/Source/core/css/StylePropertySet.cpp b/third_party/WebKit/Source/core/css/StylePropertySet.cpp |
index 2446f3f6b1069507df4b23b9ba1731c189efac36..3888238eabe2e981fc9e624d0e24086392e76310 100644 |
--- a/third_party/WebKit/Source/core/css/StylePropertySet.cpp |
+++ b/third_party/WebKit/Source/core/css/StylePropertySet.cpp |
@@ -384,11 +384,13 @@ void MutableStylePropertySet::parseDeclarationList( |
StyleSheetContents* contextStyleSheet) { |
m_propertyVector.clear(); |
- CSSParserContext context(cssParserMode(), |
- UseCounter::getFrom(contextStyleSheet)); |
+ CSSParserContext* context; |
if (contextStyleSheet) { |
- context = contextStyleSheet->parserContext(); |
- context.setMode(cssParserMode()); |
+ context = new CSSParserContext(contextStyleSheet->parserContext(), |
+ UseCounter::getFrom(contextStyleSheet)); |
+ context->setMode(cssParserMode()); |
+ } else { |
+ context = new CSSParserContext(cssParserMode()); |
} |
CSSParser::parseDeclarationList(context, this, styleDeclaration); |