[cairo-commit] cairo/src cairo.c,1.121,1.122

Carl Worth commit at pdx.freedesktop.org
Sat Aug 6 16:38:36 PDT 2005


Committed by: cworth

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

Modified Files:
	cairo.c 
Log Message:

2005-08-06  Carl Worth  <cworth at cworth.org>

        * src/cairo.c (cairo_get_font_face): Fix to return
        &_cairo_font_face_nil instead of NULL on error.


Index: cairo.c
===================================================================
RCS file: /cvs/cairo/cairo/src/cairo.c,v
retrieving revision 1.121
retrieving revision 1.122
diff -u -d -r1.121 -r1.122
--- cairo.c	6 Aug 2005 03:15:19 -0000	1.121
+++ cairo.c	6 Aug 2005 23:38:34 -0000	1.122
@@ -1687,16 +1687,13 @@
 
     if (cr->status) {
 	_cairo_set_error (cr, cr->status);
-	return NULL;
+	return (cairo_font_face_t*) &_cairo_font_face_nil;
     }
 
     cr->status = _cairo_gstate_get_font_face (cr->gstate, &font_face);
     if (cr->status) {
 	_cairo_set_error (cr, cr->status);
-	/* XXX: When available:
-	return _cairo_font_face_nil;
-	*/
-	return NULL;
+	return (cairo_font_face_t*) &_cairo_font_face_nil;
     }
 
     return font_face;




More information about the cairo-commit mailing list