diff options
Diffstat (limited to 'libskrift_open_font_mem.c')
-rw-r--r-- | libskrift_open_font_mem.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/libskrift_open_font_mem.c b/libskrift_open_font_mem.c index 3828546..bda4252 100644 --- a/libskrift_open_font_mem.c +++ b/libskrift_open_font_mem.c @@ -4,15 +4,5 @@ int libskrift_open_font_mem(LIBSKRIFT_FONT **fontp, const void *mem, size_t size) { - *fontp = calloc(1, sizeof(**fontp)); - if (!*fontp) - return -1; - (*fontp)->refcount = 1; - (*fontp)->font = sft_loadmem(mem, size); - if (!(*fontp)->font) { - free(*fontp); - *fontp = NULL; - return -1; - } - return 0; + return libskrift_open_font___(fontp, mem, NULL, NULL, size); } |