[cairo-commit] cairo/src cairo.h,1.134,1.135

Carl Worth commit at pdx.freedesktop.org
Wed Jul 20 19:23:21 PDT 2005


Committed by: cworth

Update of /cvs/cairo/cairo/src
In directory gabe:/tmp/cvs-serv1322/src

Modified Files:
	cairo.h 
Log Message:

        * src/cairo.h (CAIRO_CONTENT_VALID): Fix macro to not consider
        CAIRO_FORMAT_ARGB32 (==0) as a valid cairo_content_t.


Index: cairo.h
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo.h,v
retrieving revision 1.134
retrieving revision 1.135
diff -u -d -r1.134 -r1.135
--- cairo.h	8 Jul 2005 17:12:29 -0000	1.134
+++ cairo.h	21 Jul 2005 02:23:19 -0000	1.135
@@ -907,9 +907,11 @@
     CAIRO_CONTENT_COLOR_ALPHA	= 0x3000
 } cairo_content_t;
 
-#define CAIRO_CONTENT_VALID(content) (((content) & ~(CAIRO_CONTENT_COLOR | \
-						     CAIRO_CONTENT_ALPHA | \
-						     CAIRO_CONTENT_COLOR_ALPHA)) == 0)
+#define CAIRO_CONTENT_VALID(content) ((content) && 			         \
+				      (((content) & ~(CAIRO_CONTENT_COLOR |      \
+						      CAIRO_CONTENT_ALPHA |      \
+						      CAIRO_CONTENT_COLOR_ALPHA))\
+				       == 0))
 
 cairo_surface_t *
 cairo_surface_create_similar (cairo_surface_t  *other,




More information about the cairo-commit mailing list