[cairo-ft-font] Always call _cairo_ft_unscaled_font_fini ().

The _cairo_ft_unscaled_font_fini() was skipped during the destroy for
fonts generated by cairo_ft_font_face_create_for_ft_face(). However
this causes a mutex to be 'leaked' for each font.
This commit is contained in:
Chris Wilson 2007-10-04 14:59:55 +01:00
parent de1f92ae14
commit 4cffdf2681

View file

@ -486,6 +486,8 @@ _cairo_ft_unscaled_font_destroy (void *abstract_font)
*/
if (unscaled->faces && !unscaled->faces->unscaled)
cairo_font_face_destroy (&unscaled->faces->base);
unscaled->face = NULL;
} else {
cairo_ft_unscaled_font_map_t *font_map;
@ -497,10 +499,10 @@ _cairo_ft_unscaled_font_destroy (void *abstract_font)
&unscaled->base.hash_entry);
_font_map_release_face_lock_held (font_map, unscaled);
_cairo_ft_unscaled_font_fini (unscaled);
_cairo_ft_unscaled_font_map_unlock ();
}
_cairo_ft_unscaled_font_fini (unscaled);
}
static cairo_bool_t