truetype: Truncate the instructions upto 16-bit per a glyph.

This commit is contained in:
suzuki toshiya 2009-07-03 18:01:34 +09:00
parent de9c435bc1
commit ad2badcb44
2 changed files with 14 additions and 1 deletions

View File

@ -1,3 +1,10 @@
2009-07-03 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
truetype: Truncate the instructions upto 16-bit per a glyph.
* src/truetype/ttgload.c (TT_Hint_Glyph): Truncate
the instructions upto 16-bit length per a glyph.
2009-07-03 suzuki toshiya <mpsuzuki@hiroshima-u.ac.jp>
truetype: Cast the numerical operands to 32-bit for LP64 systems.

View File

@ -633,7 +633,13 @@
#ifdef TT_USE_BYTECODE_INTERPRETER
n_ins = loader->glyph->control_len;
if ( loader->glyph->control_len > 0xFFFFL )
{
FT_TRACE1(( "TT_Hint_Glyph: too long instructions " ));
FT_TRACE1(( "(0x%lx byte) is truncated\n",
loader->glyph->control_len ));
}
n_ins = (FT_UInt)( loader->glyph->control_len );
#endif
origin = zone->cur[zone->n_points - 4].x;