mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-05-05 11:08:12 +02:00
[cairo-scaled-font-subsets] Add missing malloc check.
A minor oversight in d77b04fd06.
This commit is contained in:
parent
22facbe66e
commit
5b7903d5a7
1 changed files with 1 additions and 1 deletions
|
|
@ -810,7 +810,7 @@ _cairo_scaled_font_subsets_foreach_internal (cairo_scaled_font_subsets_t
|
|||
|
||||
collection.glyphs = _cairo_malloc_ab (collection.glyphs_size, sizeof(unsigned long));
|
||||
collection.utf8 = _cairo_malloc_ab (collection.glyphs_size, sizeof(char *));
|
||||
if (collection.glyphs == NULL)
|
||||
if (collection.glyphs == NULL || collection.utf8 == NULL)
|
||||
return _cairo_error (CAIRO_STATUS_NO_MEMORY);
|
||||
|
||||
collection.font_subset_callback = font_subset_callback;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue