[PATCH] cssparser.cpp

Pascal Letourneau pletourn at globetrotter.net
Mon Sep 23 20:54:16 BST 2002


Hi

This fix a problem on http://nwn.bioware.com/downloads/linuxclient.html

The stylesheet contains the line
background: #000000

The CSS parser wrongly interprets '#000000' as a background-position.

Pascal Létourneau

Index: cssparser.cpp
===================================================================
RCS file: /home2/webcvs/mirror/kdelibs/khtml/css/cssparser.cpp,v
retrieving revision 1.217
diff -u -3 -p -r1.217 cssparser.cpp
--- cssparser.cpp       15 Sep 2002 14:12:45 -0000      1.217
+++ cssparser.cpp       23 Sep 2002 19:45:23 -0000
@@ -2530,6 +2558,7 @@ StyleBaseImpl::parseUnit(const QChar * c
            return new CSSPrimitiveValueImpl( 1., 
CSSPrimitiveValue::CSS_HTML_RELATIVE );
        if ( value < 0 && (allowedUnits & NONNEGATIVE) )
            return 0;
+       return 0; // parse error
     }

     if(split > endP) // no unit





More information about the kfm-devel mailing list