From 41bd254198b8b879a562a85f7dc868c3c0f7fbc1 Mon Sep 17 00:00:00 2001 From: marha Date: Mon, 12 Mar 2012 10:33:22 +0100 Subject: Updated to freetype-2.4.9 --- freetype/src/psnames/psmodule.c | 20 ++++++++++++++++---- 1 file changed, 16 insertions(+), 4 deletions(-) (limited to 'freetype/src/psnames/psmodule.c') diff --git a/freetype/src/psnames/psmodule.c b/freetype/src/psnames/psmodule.c index 752869693..361917415 100644 --- a/freetype/src/psnames/psmodule.c +++ b/freetype/src/psnames/psmodule.c @@ -521,7 +521,7 @@ #ifdef FT_CONFIG_OPTION_ADOBE_GLYPH_LIST - FT_DEFINE_SERVICE_PSCMAPSREC(pscmaps_interface, + FT_DEFINE_SERVICE_PSCMAPSREC(pscmaps_interface, (PS_Unicode_ValueFunc) ps_unicode_value, (PS_Unicodes_InitFunc) ps_unicodes_init, (PS_Unicodes_CharIndexFunc)ps_unicodes_char_index, @@ -536,7 +536,7 @@ #else - FT_DEFINE_SERVICE_PSCMAPSREC(pscmaps_interface, + FT_DEFINE_SERVICE_PSCMAPSREC(pscmaps_interface, 0, 0, 0, @@ -552,7 +552,7 @@ #endif /* FT_CONFIG_OPTION_ADOBE_GLYPH_LIST */ - FT_DEFINE_SERVICEDESCREC1(pscmaps_services, + FT_DEFINE_SERVICEDESCREC1(pscmaps_services, FT_SERVICE_ID_POSTSCRIPT_CMAPS, &FT_PSCMAPS_INTERFACE_GET ) @@ -563,7 +563,19 @@ psnames_get_service( FT_Module module, const char* service_id ) { + /* FT_PSCMAPS_SERVICES_GET derefers `library' in PIC mode */ +#ifdef FT_CONFIG_OPTION_PIC + FT_Library library; + + + if ( !module ) + return NULL; + library = module->library; + if ( !library ) + return NULL; +#else FT_UNUSED( module ); +#endif return ft_service_list_lookup( FT_PSCMAPS_SERVICES_GET, service_id ); } @@ -578,7 +590,7 @@ #endif FT_DEFINE_MODULE(psnames_module_class, - + 0, /* this is not a font driver, nor a renderer */ sizeof ( FT_ModuleRec ), -- cgit v1.2.3