[truetype] Fix SCANTYPE instruction (#49394).

* src/truetype/ttinterp.c (Ins_SCANTYPE): Only use lower 16bits.
This commit is contained in:
Werner Lemberg 2016-10-22 19:16:08 +02:00
parent 577414030a
commit 5081674c5f
2 changed files with 8 additions and 2 deletions

View File

@ -1,3 +1,9 @@
2016-10-22 Werner Lemberg <wl@gnu.org>
[truetype] Fix SCANTYPE instruction (#49394).
* src/truetype/ttinterp.c (Ins_SCANTYPE): Only use lower 16bits.
2016-10-22 Werner Lemberg <wl@gnu.org>
[sfnt] Improve handling of invalid post 2.5 tables [#49393].

View File

@ -5173,14 +5173,14 @@
/* */
/* SCANTYPE[]: SCAN TYPE */
/* Opcode range: 0x8D */
/* Stack: uint32? --> */
/* Stack: uint16 --> */
/* */
static void
Ins_SCANTYPE( TT_ExecContext exc,
FT_Long* args )
{
if ( args[0] >= 0 )
exc->GS.scan_type = (FT_Int)args[0];
exc->GS.scan_type = (FT_Int)args[0] & 0xFFFFU;
}