/[freetype]/freetype2/src/gxvalid/gxvmort.c
ViewVC logotype

Diff of /freetype2/src/gxvalid/gxvmort.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by wl, Wed Aug 31 22:39:23 2005 UTC revision 1.3 by wl, Mon Sep 5 19:31:27 2005 UTC
# Line 25  Line 25 
25    
26    
27  #include "gxvmort.h"  #include "gxvmort.h"
28    #include "gxvfeat.h"
29    
30    
31    /*************************************************************************/    /*************************************************************************/
# Line 88  Line 89 
89     * nFeatureFlags is typed to FT_UInt to accept that in     * nFeatureFlags is typed to FT_UInt to accept that in
90     * mort (typed FT_UShort) and morx (typed FT_ULong).     * mort (typed FT_UShort) and morx (typed FT_ULong).
91     */     */
92    static void    FT_LOCAL_DEF( void )
93    gxv_mort_featurearray_validate( FT_Bytes       table,    gxv_mort_featurearray_validate( FT_Bytes       table,
94                                    FT_Bytes       limit,                                    FT_Bytes       limit,
95                                    FT_UInt        nFeatureFlags,                                    FT_UInt        nFeatureFlags,
# Line 120  Line 121 
121    }    }
122    
123    
124    static void    FT_LOCAL_DEF( void )
125    gxv_mort_coverage_validate( FT_UShort      coverage,    gxv_mort_coverage_validate( FT_UShort      coverage,
126                                GXV_Validator  valid )                                GXV_Validator  valid )
127    {    {
# Line 184  Line 185 
185        coverage        = FT_NEXT_USHORT( p );        coverage        = FT_NEXT_USHORT( p );
186        subFeatureFlags = FT_NEXT_ULONG( p );        subFeatureFlags = FT_NEXT_ULONG( p );
187    
188        GXV_TRACE(( "validate chain subtable %d/%d (%d bytes)\n",        GXV_TRACE(( "validating chain subtable %d/%d (%d bytes)\n",
189                    i + 1, nSubtables, length ));                    i + 1, nSubtables, length ));
190        type = coverage & 0x0007;        type = coverage & 0x0007;
191        rest = length - ( 2 + 2 + 4 );        rest = length - ( 2 + 2 + 4 );
# Line 258  Line 259 
259      valid->face = face;      valid->face = face;
260      limit       = valid->root->limit;      limit       = valid->root->limit;
261    
262      FT_TRACE3(( "validation mort table\n" ));      FT_TRACE3(( "validating `mort' table\n" ));
263      GXV_INIT;      GXV_INIT;
264    
265      GXV_LIMIT_CHECK( 4 + 4 );      GXV_LIMIT_CHECK( 4 + 4 );
# Line 270  Line 271 
271    
272      for ( i = 0; i < nChains; i++ )      for ( i = 0; i < nChains; i++ )
273      {      {
274        GXV_TRACE(( "validate chain %d/%d\n", i + 1, nChains ));        GXV_TRACE(( "validating chain %d/%d\n", i + 1, nChains ));
275        GXV_32BIT_ALIGNMENT_VALIDATE( p - table );        GXV_32BIT_ALIGNMENT_VALIDATE( p - table );
276        gxv_mort_chain_validate( p, limit, valid );        gxv_mort_chain_validate( p, limit, valid );
277        p += valid->subtable_length;        p += valid->subtable_length;

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26