cache: Fix some data types mismatching with their sources.

This commit is contained in:
suzuki toshiya 2009-07-03 18:01:30 +09:00
parent d22f5a532a
commit 2bb188d0f2
7 changed files with 37 additions and 12 deletions

View File

@ -1,3 +1,28 @@
2009-07-03 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
cache: Fix some data types mismatching with their sources.
* src/cache/ftccache.h: The type of return value
by FTC_Node_WeightFunc function is changed to
FT_Offset. The type of FTC_CacheClass->cache_size
is changed to FT_Offset, too.
* src/cache/ftccback.h (ft_inode_weight,
ftc_snode_weight): Ditto.
* src/cache/ftccmap.c (ftc_cmap_node_weight): Ditto.
* src/cache/ftcimage.c (ftc_inode_weight,
FTC_INode_Weight): Ditto.
* src/cache/ftcsbits.c (ftc_snode_weight,
FTC_SNode_Weight): Ditto.
* src/cache/ftcmru.h: The type of
FTC_MruListClass->node_size is changed to FT_Offset,
because it is passed to FT_ALLOC() to specify the
size of buffer.
2009-07-03 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
XXX_cmap_encoding_char_next() return FT_UInt32 values.

View File

@ -91,7 +91,7 @@ FT_BEGIN_HEADER
FT_Pointer query,
FTC_Cache cache );
typedef FT_ULong
typedef FT_Offset
(*FTC_Node_WeightFunc)( FTC_Node node,
FTC_Cache cache );
@ -121,7 +121,7 @@ FT_BEGIN_HEADER
FTC_Node_CompareFunc node_remove_faceid;
FTC_Node_FreeFunc node_free;
FT_UInt cache_size;
FT_Offset cache_size;
FTC_Cache_InitFunc cache_init;
FTC_Cache_DoneFunc cache_done;

View File

@ -36,7 +36,7 @@
FT_Pointer gquery,
FTC_Cache cache );
FT_LOCAL( FT_ULong )
FT_LOCAL( FT_Offset )
ftc_inode_weight( FTC_Node inode,
FTC_Cache cache );
@ -50,7 +50,7 @@
FT_Pointer gquery,
FTC_Cache cache );
FT_LOCAL( FT_ULong )
FT_LOCAL( FT_Offset )
ftc_snode_weight( FTC_Node snode,
FTC_Cache cache );

2
src/cache/ftccmap.c vendored
View File

@ -174,7 +174,7 @@
/* compute the weight of a given cmap node */
FT_CALLBACK_DEF( FT_ULong )
FT_CALLBACK_DEF( FT_Offset )
ftc_cmap_node_weight( FTC_Node cnode,
FTC_Cache cache )
{

View File

@ -103,12 +103,12 @@
}
FT_LOCAL_DEF( FT_ULong )
FT_LOCAL_DEF( FT_Offset )
ftc_inode_weight( FTC_Node ftcinode,
FTC_Cache ftccache )
{
FTC_INode inode = (FTC_INode)ftcinode;
FT_ULong size = 0;
FT_Offset size = 0;
FT_Glyph glyph = inode->glyph;
FT_UNUSED( ftccache );
@ -151,7 +151,7 @@
#if 0
FT_LOCAL_DEF( FT_ULong )
FT_LOCAL_DEF( FT_Offset )
FTC_INode_Weight( FTC_INode inode )
{
return ftc_inode_weight( FTC_NODE( inode ), NULL );

2
src/cache/ftcmru.h vendored
View File

@ -107,7 +107,7 @@ FT_BEGIN_HEADER
typedef struct FTC_MruListClassRec_
{
FT_UInt node_size;
FT_Offset node_size;
FTC_MruNode_CompareFunc node_compare;
FTC_MruNode_InitFunc node_init;
FTC_MruNode_ResetFunc node_reset;

View File

@ -263,7 +263,7 @@
}
FT_LOCAL_DEF( FT_ULong )
FT_LOCAL_DEF( FT_Offset )
ftc_snode_weight( FTC_Node ftcsnode,
FTC_Cache cache )
{
@ -271,7 +271,7 @@
FT_UInt count = snode->count;
FTC_SBit sbit = snode->sbits;
FT_Int pitch;
FT_ULong size;
FT_Offset size;
FT_UNUSED( cache );
@ -300,7 +300,7 @@
#if 0
FT_LOCAL_DEF( FT_ULong )
FT_LOCAL_DEF( FT_Offset )
FTC_SNode_Weight( FTC_SNode snode )
{
return ftc_snode_weight( FTC_NODE( snode ), NULL );