summaryrefslogtreecommitdiffstats
path: root/src/base/ftobjs.c
diff options
context:
space:
mode:
authorEric Vannier <evannier@google.com>2012-03-22 16:08:33 -0700
committerGeremy Condra <gcondra@google.com>2012-04-20 14:53:55 -0700
commit41371e1e39c8528eb0c4bc40683c736e6683e60c (patch)
treeba563af45d79cd0832305fe3833919bb2475f186 /src/base/ftobjs.c
parent27811904d8de0ce5591417812ca31163bf5aad60 (diff)
downloadandroid_external_freetype-41371e1e39c8528eb0c4bc40683c736e6683e60c.tar.gz
android_external_freetype-41371e1e39c8528eb0c4bc40683c736e6683e60c.tar.bz2
android_external_freetype-41371e1e39c8528eb0c4bc40683c736e6683e60c.zip
Update to freetype 2.4.9
This was done by applying the entire 2.4.9 except for the following exceptions: - files that were new, or were not present originally in the version of freetype we were using (meaning that they are present in 2.4.8, and in 2.4.9, but were never integrated into the Android tree because they are not used in the Android tree). - ftmodule.h: given that we support fewer modules than in upstream 2.4.9 (same as Android), the file was left unchanged (and there were no changes from the official 2.4.8 to 2.4.9 - ftoption.h: same reasons as ftmodule.h Change-Id: Id251f2cc5ca1c864f9a4cc0c67b94025ee3ccc4a
Diffstat (limited to 'src/base/ftobjs.c')
-rw-r--r--src/base/ftobjs.c27
1 files changed, 12 insertions, 15 deletions
diff --git a/src/base/ftobjs.c b/src/base/ftobjs.c
index 64575af..36ee797 100644
--- a/src/base/ftobjs.c
+++ b/src/base/ftobjs.c
@@ -4,7 +4,7 @@
/* */
/* The FreeType private base classes (body). */
/* */
-/* Copyright 1996-2011 by */
+/* Copyright 1996-2012 by */
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
/* */
/* This file is part of the FreeType project, and may only be used, */
@@ -445,6 +445,10 @@
else
prev->next = cur->next;
+ /* finalize client-specific data */
+ if ( slot->generic.finalizer )
+ slot->generic.finalizer( slot );
+
ft_glyphslot_done( slot );
FT_FREE( slot );
break;
@@ -1187,7 +1191,7 @@
/* there's a Mac-specific extended implementation of FT_New_Face() */
/* in src/base/ftmac.c */
-#if !defined( FT_MACINTOSH ) || defined( DARWIN_NO_CARBON )
+#ifndef FT_MACINTOSH
/* documentation is in freetype.h */
@@ -1211,7 +1215,7 @@
return FT_Open_Face( library, &args, face_index, aface );
}
-#endif /* defined( FT_MACINTOSH ) && !defined( DARWIN_NO_CARBON ) */
+#endif
/* documentation is in freetype.h */
@@ -1520,7 +1524,7 @@
}
-#if !defined( FT_MACINTOSH ) || defined( DARWIN_NO_CARBON )
+#ifndef FT_MACINTOSH
/* The resource header says we've got resource_cnt `POST' (type1) */
/* resources in this file. They all need to be coalesced into */
@@ -1875,7 +1879,7 @@
for ( i = 0; i < FT_RACCESS_N_RULES; i++ )
{
- is_darwin_vfs = raccess_rule_by_darwin_vfs( i );
+ is_darwin_vfs = ft_raccess_rule_by_darwin_vfs( library, i );
if ( is_darwin_vfs && vfs_rfork_has_no_font )
{
FT_TRACE3(( "Skip rule %d: darwin vfs resource fork"
@@ -4085,10 +4089,10 @@
/* all child faces. */
/* */
/* <InOut> */
- /* module :: A handle to the target driver object. */
+ /* module :: A handle to the target driver object. */
/* */
/* <Note> */
- /* The driver _must_ be LOCKED! */
+ /* The driver _must_ be LOCKED! */
/* */
static void
Destroy_Module( FT_Module module )
@@ -4098,10 +4102,6 @@
FT_Library library = module->library;
- /* finalize client-data - before anything else */
- if ( module->generic.finalizer )
- module->generic.finalizer( module );
-
if ( library && library->auto_hinter == module )
library->auto_hinter = 0;
@@ -4318,6 +4318,7 @@
FT_Module* cur = library->modules;
FT_Module* limit = cur + library->num_modules;
+
for ( ; cur < limit; cur++ )
{
if ( cur[0] != module )
@@ -4511,10 +4512,6 @@
memory = library->memory;
- /* Discard client-data */
- if ( library->generic.finalizer )
- library->generic.finalizer( library );
-
/*
* Close all faces in the library. If we don't do this, we can have
* some subtle memory leaks.