From f33438df2240d186de94e44c74ce66bd3bd0db12 Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Sat, 24 Jan 2009 13:07:25 +0000 Subject: Ensure height values are positive svn path=/trunk/libcss/; revision=6226 --- src/parse/properties.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/parse') 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; } -- cgit v1.2.3