diff options
author | John Mark Bell <jmb@netsurf-browser.org> | 2009-01-24 13:07:25 +0000 |
---|---|---|
committer | John Mark Bell <jmb@netsurf-browser.org> | 2009-01-24 13:07:25 +0000 |
commit | f33438df2240d186de94e44c74ce66bd3bd0db12 (patch) | |
tree | 21de958bb145c36793808b11837e9510ebbe0499 | |
parent | 926809529b6fd4b385b76a4b7589b03cd0cde929 (diff) | |
download | libcss-f33438df2240d186de94e44c74ce66bd3bd0db12.tar.gz |
Ensure height values are positive
svn path=/trunk/libcss/; revision=6226
-rw-r--r-- | src/parse/properties.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/parse/properties.c b/src/parse/properties.c index b646ecf..b6ace4a 100644 --- a/src/parse/properties.c +++ b/src/parse/properties.c @@ -3249,6 +3249,10 @@ css_error parse_height(css_language *c, if (unit & UNIT_ANGLE || unit & UNIT_TIME || unit & UNIT_FREQ) return CSS_INVALID; + /* Negative height is illegal */ + if (length < 0) + return CSS_INVALID; + value = HEIGHT_SET; } |