Commit fbd24523461d57d38bd040d842f9fba2690545cd

Werner Lemberg 2018-11-06T11:15:31

[pshinter] Fix numeric overflow. Reported as https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11242 * src/pshinter/pshrec.c (ps_dimension_add_t1stem): Implement it.

diff --git a/ChangeLog b/ChangeLog
index 3b73bac..48e7836 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,15 @@
 2018-11-06  Werner Lemberg  <wl@gnu.org>
 
+	[pshinter] Fix numeric overflow.
+
+	Reported as
+
+	  https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11242
+
+	* src/pshinter/pshrec.c (ps_dimension_add_t1stem): Implement it.
+
+2018-11-06  Werner Lemberg  <wl@gnu.org>
+
 	[psaux] Fix timeout in old CFF engine.
 
 	Reported as
diff --git a/src/pshinter/pshrec.c b/src/pshinter/pshrec.c
index 401ab19..7633c5e 100644
--- a/src/pshinter/pshrec.c
+++ b/src/pshinter/pshrec.c
@@ -666,7 +666,7 @@
       if ( len == -21 )
       {
         flags |= PS_HINT_FLAG_BOTTOM;
-        pos   += len;
+        pos    = ADD_INT( pos, len );
       }
       len = 0;
     }