[cairo-boilerplate] Protect against the nil cairo_scaled_font_t

Beware the NULL pointer deference when trying to adjust the max glyph
cache size...
This commit is contained in:
Chris Wilson 2007-05-08 16:23:07 +01:00
parent b85920684f
commit efd212bfa2

View file

@ -443,5 +443,8 @@ void
cairo_boilerplate_scaled_font_set_max_glyphs_cached (cairo_scaled_font_t *scaled_font,
int max_glyphs)
{
if (cairo_scaled_font_status (scaled_font))
return;
scaled_font->glyphs->max_size = max_glyphs;
}