mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-01-18 10:00:31 +01:00
font: Check return value from _cairo_ft_unscaled_font_lock_face
cairo-ft-font.c: In function ‘_cairo_ft_has_color_glyphs’:
cairo-ft-font.c:3011:9: warning: ignoring return value of ‘_cairo_ft_unscaled_font_lock_face’, declared with attribute warn_unused_result [-Wunused-result]
_cairo_ft_unscaled_font_lock_face (unscaled);
^
This commit is contained in:
parent
bc335a741f
commit
1cbebafe89
1 changed files with 5 additions and 2 deletions
|
|
@ -3008,8 +3008,11 @@ _cairo_ft_has_color_glyphs (void *scaled)
|
|||
cairo_ft_unscaled_font_t *unscaled = ((cairo_ft_scaled_font_t *)scaled)->unscaled;
|
||||
|
||||
if (!unscaled->have_color_set) {
|
||||
_cairo_ft_unscaled_font_lock_face (unscaled);
|
||||
_cairo_ft_unscaled_font_unlock_face (unscaled);
|
||||
FT_Face face;
|
||||
face = _cairo_ft_unscaled_font_lock_face (unscaled);
|
||||
if (unlikely (face == NULL))
|
||||
return FALSE;
|
||||
_cairo_ft_unscaled_font_unlock_face (unscaled);
|
||||
}
|
||||
|
||||
return unscaled->have_color;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue