| Index: third_party/WebKit/Source/core/css/parser/CSSParserFastPaths.cpp
|
| diff --git a/third_party/WebKit/Source/core/css/parser/CSSParserFastPaths.cpp b/third_party/WebKit/Source/core/css/parser/CSSParserFastPaths.cpp
|
| index f8bd98e37ec7dd37955f335aff42f375e53808f1..d1206ece38309489c1c8fb82254af83841625833 100644
|
| --- a/third_party/WebKit/Source/core/css/parser/CSSParserFastPaths.cpp
|
| +++ b/third_party/WebKit/Source/core/css/parser/CSSParserFastPaths.cpp
|
| @@ -109,15 +109,14 @@ static PassRefPtrWillBeRawPtr<CSSValue> parseSimpleLengthValue(CSSPropertyID pro
|
| }
|
|
|
| if (unit == CSSPrimitiveValue::UnitType::Number) {
|
| - bool quirksMode = isQuirksModeBehavior(cssParserMode);
|
| - bool svgMode = cssParserMode == SVGAttributeMode;
|
| - if (number && (!quirksMode && !svgMode))
|
| - return nullptr;
|
| - if (svgMode)
|
| + if (cssParserMode == SVGAttributeMode)
|
| unit = CSSPrimitiveValue::UnitType::UserUnits;
|
| - else
|
| + else if (!number)
|
| unit = CSSPrimitiveValue::UnitType::Pixels;
|
| + else
|
| + return nullptr;
|
| }
|
| +
|
| if (number < 0 && !acceptsNegativeNumbers)
|
| return nullptr;
|
|
|
|
|