summaryrefslogtreecommitdiff
path: root/src/parse/properties/utils.c
diff options
context:
space:
mode:
authorJohn Mark Bell <jmb@netsurf-browser.org>2009-11-22 13:03:21 +0000
committerJohn Mark Bell <jmb@netsurf-browser.org>2009-11-22 13:03:21 +0000
commit6591ba35f6fa5dc3867c5ff27ebef523ce8729d3 (patch)
tree310e46cb2386d93c29583966728d81411f9f6a00 /src/parse/properties/utils.c
parente00a1f0dffe58a36d30a93a073da31562a9ffa57 (diff)
downloadlibcss-6591ba35f6fa5dc3867c5ff27ebef523ce8729d3.tar.gz
libcss-6591ba35f6fa5dc3867c5ff27ebef523ce8729d3.tar.bz2
Lose redundant assignments.
Drop some dead code. Avoid a potential NULL dereference. Add missing "break" in initial substate of block context parser svn path=/trunk/libcss/; revision=9678
Diffstat (limited to 'src/parse/properties/utils.c')
-rw-r--r--src/parse/properties/utils.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/parse/properties/utils.c b/src/parse/properties/utils.c
index c7af699..8676015 100644
--- a/src/parse/properties/utils.c
+++ b/src/parse/properties/utils.c
@@ -48,8 +48,8 @@ css_error parse_colour_specifier(css_language *c,
token->type != CSS_TOKEN_HASH &&
token->type != CSS_TOKEN_FUNCTION)) {
if (c->sheet->quirks_allowed == false ||
- (token != NULL &&
- token->type != CSS_TOKEN_NUMBER &&
+ token == NULL ||
+ (token->type != CSS_TOKEN_NUMBER &&
token->type != CSS_TOKEN_DIMENSION))
goto invalid;
}