[base] Don't initialize unused `driver->glyph_loader'.
* src/base/ftobjs.c (Destroy_Driver): Don't call `FT_GlyphLoader_Done'. (FT_Add_Module): Don't call `FT_GlyphLoader_New'.
This commit is contained in:
parent
5163425344
commit
603292d7b0
|
@ -1,3 +1,11 @@
|
|||
2015-01-14 Behdad Esfahbod <behdad@behdad.org>
|
||||
|
||||
[base] Don't initialize unused `driver->glyph_loader'.
|
||||
|
||||
* src/base/ftobjs.c (Destroy_Driver): Don't call
|
||||
`FT_GlyphLoader_Done'.
|
||||
(FT_Add_Module): Don't call `FT_GlyphLoader_New'.
|
||||
|
||||
2015-01-14 Behdad Esfahbod <behdad@behdad.org>
|
||||
|
||||
[base] Don't allocate `library->raster_pool' anymore.
|
||||
|
|
|
@ -740,9 +740,8 @@ FT_BEGIN_HEADER
|
|||
/* faces_list :: The list of faces currently opened by this */
|
||||
/* driver. */
|
||||
/* */
|
||||
/* glyph_loader :: The glyph loader for all faces managed by this */
|
||||
/* driver. This object isn't defined for unscalable */
|
||||
/* formats. */
|
||||
/* glyph_loader :: Unused. Used to be glyph loader for all faces */
|
||||
/* managed by this driver. */
|
||||
/* */
|
||||
typedef struct FT_DriverRec_
|
||||
{
|
||||
|
|
|
@ -968,10 +968,6 @@
|
|||
(FT_List_Destructor)destroy_face,
|
||||
driver->root.memory,
|
||||
driver );
|
||||
|
||||
/* check whether we need to drop the driver's glyph loader */
|
||||
if ( FT_DRIVER_USES_OUTLINES( driver ) )
|
||||
FT_GlyphLoader_Done( driver->glyph_loader );
|
||||
}
|
||||
|
||||
|
||||
|
@ -4313,17 +4309,10 @@
|
|||
/* if the module is a font driver */
|
||||
if ( FT_MODULE_IS_DRIVER( module ) )
|
||||
{
|
||||
/* allocate glyph loader if needed */
|
||||
FT_Driver driver = FT_DRIVER( module );
|
||||
|
||||
|
||||
driver->clazz = (FT_Driver_Class)module->clazz;
|
||||
if ( FT_DRIVER_USES_OUTLINES( driver ) )
|
||||
{
|
||||
error = FT_GlyphLoader_New( memory, &driver->glyph_loader );
|
||||
if ( error )
|
||||
goto Fail;
|
||||
}
|
||||
}
|
||||
|
||||
if ( clazz->module_init )
|
||||
|
@ -4340,15 +4329,6 @@
|
|||
return error;
|
||||
|
||||
Fail:
|
||||
if ( FT_MODULE_IS_DRIVER( module ) )
|
||||
{
|
||||
FT_Driver driver = FT_DRIVER( module );
|
||||
|
||||
|
||||
if ( FT_DRIVER_USES_OUTLINES( driver ) )
|
||||
FT_GlyphLoader_Done( driver->glyph_loader );
|
||||
}
|
||||
|
||||
if ( FT_MODULE_IS_RENDERER( module ) )
|
||||
{
|
||||
FT_Renderer renderer = FT_RENDERER( module );
|
||||
|
|
Loading…
Reference in New Issue