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 f963e93fd3eb57920355d5c20eceefdf9fe0bc3b..33a29e13cf63751eac303eef181606efce2df827 100644 |
--- a/third_party/WebKit/Source/core/css/parser/CSSParserFastPaths.cpp |
+++ b/third_party/WebKit/Source/core/css/parser/CSSParserFastPaths.cpp |
@@ -387,7 +387,7 @@ static bool fastParseColorInternal(RGBA32& rgb, const CharacterType* characters, |
if (length >= 4 && characters[0] == '#') |
return Color::parseHexColor(characters + 1, length - 1, rgb); |
- if (quirksMode && length >= 3) { |
+ if (quirksMode && (length == 3 || length == 6)) { |
if (Color::parseHexColor(characters, length, rgb)) |
return true; |
} |