1
0
mirror of https://github.com/roytam1/UXP.git synced 2026-05-26 13:58:49 +00:00

[gfx] Use calloc for cairo font-creation functions.

This commit is contained in:
Moonchild
2024-05-21 15:04:22 +02:00
committed by roytam1
parent 7672f932f7
commit 7d2ecc13dd
+2 -2
View File
@@ -1726,7 +1726,7 @@ _cairo_cff_font_create (cairo_scaled_font_subset_t *scaled_font_subset,
if (unlikely (status))
return status;
font = malloc (sizeof (cairo_cff_font_t));
font = calloc (1, sizeof (cairo_cff_font_t));
if (unlikely (font == NULL))
return _cairo_error (CAIRO_STATUS_NO_MEMORY);
@@ -1994,7 +1994,7 @@ _cairo_cff_font_fallback_create (cairo_scaled_font_subset_t *scaled_font_subset
cairo_status_t status;
cairo_cff_font_t *font;
font = malloc (sizeof (cairo_cff_font_t));
font = calloc (1, sizeof (cairo_cff_font_t));
if (unlikely (font == NULL))
return _cairo_error (CAIRO_STATUS_NO_MEMORY);