Index: Source/core/css/parser/SizesAttributeParser.cpp |
diff --git a/Source/core/css/parser/SizesAttributeParser.cpp b/Source/core/css/parser/SizesAttributeParser.cpp |
index 4fd32365b7f52f793a534c9e60553c2585ab4ed0..d31b2c1a3d156f2dceef304894a720fc2c25bb6a 100644 |
--- a/Source/core/css/parser/SizesAttributeParser.cpp |
+++ b/Source/core/css/parser/SizesAttributeParser.cpp |
@@ -35,8 +35,7 @@ bool SizesAttributeParser::calculateLengthInPixels(TokenIterator startToken, Tok |
return true; |
} |
} |
- } |
- if (type == FunctionToken) { |
+ } else if (type == FunctionToken) { |
eseidel
2014/04/20 21:27:43
This change has no effect, but OK. If the earlier
|
// FIXME - Handle calc() functions here! |
} |
return false; |
@@ -101,6 +100,8 @@ bool SizesAttributeParser::parseMediaConditionAndLength(TokenIterator startToken |
bool SizesAttributeParser::parse(Vector<MediaQueryToken>& tokens) |
{ |
+ if (tokens.isEmpty()) |
+ return false; |
TokenIterator startToken = tokens.begin(); |
TokenIterator endToken; |
// Split on a comma token, and send the result tokens to be parsed as (media-condition, length) pairs |