From 17196b7c747cf8a7309efda54c99a89d456f0512 Mon Sep 17 00:00:00 2001 From: Werner Lemberg Date: Sat, 5 Aug 2017 18:58:34 +0200 Subject: [PATCH] [truetype] Integer overflow. Reported as https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2868 * src/truetype/ttinterp.c (Ins_ALIGNRP): Use NEG_LONG. --- ChangeLog | 10 ++++++++++ src/truetype/ttinterp.c | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 30f18b73c..987d5734c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2017-06-27 Werner Lemberg + + [truetype] Integer overflow. + + Reported as + + https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=2868 + + * src/truetype/ttinterp.c (Ins_ALIGNRP): Use NEG_LONG. + 2017-08-05 Werner Lemberg [base, truetype] New function `FT_Get_Var_Axis_Flags'. diff --git a/src/truetype/ttinterp.c b/src/truetype/ttinterp.c index 8636d5e3f..bc201554e 100644 --- a/src/truetype/ttinterp.c +++ b/src/truetype/ttinterp.c @@ -6421,7 +6421,7 @@ distance = PROJECT( exc->zp1.cur + point, exc->zp0.cur + exc->GS.rp0 ); - exc->func_move( exc, &exc->zp1, point, -distance ); + exc->func_move( exc, &exc->zp1, point, NEG_LONG( distance ) ); } exc->GS.loop--;