mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-04-26 10:10:44 +02:00
Fix to return &_cairo_font_face_nil instead of NULL on error.
This commit is contained in:
parent
8c52b287f3
commit
2f1024f83f
2 changed files with 7 additions and 5 deletions
|
|
@ -1,3 +1,8 @@
|
|||
2005-08-06 Carl Worth <cworth@cworth.org>
|
||||
|
||||
* src/cairo.c (cairo_get_font_face): Fix to return
|
||||
&_cairo_font_face_nil instead of NULL on error.
|
||||
|
||||
2005-08-06 Jeff Muizelaar <jeff@infidigm.net>
|
||||
|
||||
* test/a8-mask.c: (main): Give reason for failure.
|
||||
|
|
|
|||
|
|
@ -1687,16 +1687,13 @@ cairo_get_font_face (cairo_t *cr)
|
|||
|
||||
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;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue