| Index: Source/core/css/parser/CSSPropertyParser.cpp
|
| diff --git a/Source/core/css/parser/CSSPropertyParser.cpp b/Source/core/css/parser/CSSPropertyParser.cpp
|
| index c9c995bc63ba21fde79a60f8bb4d30c005a7ed7d..253cc9d579b12149cf47efec3d710992e2dbbcc7 100644
|
| --- a/Source/core/css/parser/CSSPropertyParser.cpp
|
| +++ b/Source/core/css/parser/CSSPropertyParser.cpp
|
| @@ -89,6 +89,7 @@ using namespace std;
|
| namespace WebCore {
|
|
|
| static const double MAX_SCALE = 1000000;
|
| +static const unsigned minRepetitions = 10000;
|
|
|
| template <unsigned N>
|
| static bool equal(const CSSParserString& a, const char (&b)[N])
|
| @@ -3797,6 +3798,10 @@ bool CSSPropertyParser::parseGridTrackRepeatFunction(CSSValueList& list)
|
|
|
| ASSERT_WITH_SECURITY_IMPLICATION(arguments->valueAt(0)->fValue > 0);
|
| size_t repetitions = arguments->valueAt(0)->fValue;
|
| + // Clamp repetitions at minRepetitions.
|
| + // http://www.w3.org/TR/css-grid-1/#repeat-notation
|
| + if (repetitions > minRepetitions)
|
| + repetitions = minRepetitions;
|
| RefPtrWillBeRawPtr<CSSValueList> repeatedValues = CSSValueList::createSpaceSeparated();
|
| arguments->next(); // Skip the repetition count.
|
| arguments->next(); // Skip the comma.
|
|
|