freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ft-devel] Memory leak in cff fonts


From: Werner LEMBERG
Subject: Re: [ft-devel] Memory leak in cff fonts
Date: Tue, 06 Jun 2006 08:44:13 +0200 (CEST)

> I think that there is memory leak in CFF font handling (FreeType
> 2.2.1).

I can confirm that.

> In cff fonts get_glyph_name callback points to:
> cff_sid_to_glyph_name from cffcmap.c
> which calls:
> cff_index_get_sid_string which allways create new string in memory.
>
> [...]
>
> I don't see any easy fix, so please find out one yourself :-)

Indeed, it is tricky.  Reason is that some of the SIDs have to be
allocated, but not all of them.  David?

> (I will fix it temporary to create copy even in t1_get_glyph_name
> and free it in ps_unicodes_init always.

Can you provide a patch?  We could add it, marked with a `FIXME'.


    Werner




reply via email to

[Prev in Thread] Current Thread [Next in Thread]