aboutsummaryrefslogtreecommitdiffstats
path: root/libskrift_close_font.c
blob: 27866661b8ed142f05627816cc46f251f4f06b35 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
/* See LICENSE file for copyright and license details. */
#include "common.h"

void
libskrift_close_font(LIBSKRIFT_FONT *font)
{
	if (font && !--font->refcount) {
		sft_freefont(font->font);
		free(font->memory_free);
		if (font->memory_unmap)
			munmap(font->memory_unmap, font->memory_size);
		free(font);
	}
}