[cff] Fix Savannah bug #44629. * src/cff/cf2font.h (CF2_MAX_SUBR), src/cff/cffgload.h (CFF_MAX_SUBRS_CALLS): Set to 16.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53
diff --git a/ChangeLog b/ChangeLog
index abefef0..ef7c131 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
2015-03-29 Werner Lemberg <wl@gnu.org>
+ [cff] Fix Savannah bug #44629.
+
+ * src/cff/cf2font.h (CF2_MAX_SUBR), src/cff/cffgload.h
+ (CFF_MAX_SUBRS_CALLS): Set to 16.
+
+2015-03-29 Werner Lemberg <wl@gnu.org>
+
[type1, truetype] Make the MM API more flexible w.r.t. `num_coords'.
This commit allows `num_coords' to be larger or smaller than the
diff --git a/src/cff/cf2font.h b/src/cff/cf2font.h
index d8860ce..86cf02f 100644
--- a/src/cff/cf2font.h
+++ b/src/cff/cf2font.h
@@ -48,7 +48,12 @@ FT_BEGIN_HEADER
#define CF2_OPERAND_STACK_SIZE 48
-#define CF2_MAX_SUBR 10 /* maximum subroutine nesting */
+#define CF2_MAX_SUBR 16 /* maximum subroutine nesting; */
+ /* only 10 are allowed but there exist */
+ /* fonts like `HiraKakuProN-W3.ttf' */
+ /* (Hiragino Kaku Gothic ProN W3; */
+ /* 8.2d6e1; 2014-12-19) that exceed */
+ /* this limit */
/* typedef is in `cf2glue.h' */
diff --git a/src/cff/cffgload.h b/src/cff/cffgload.h
index 5c52d43..5f2655f 100644
--- a/src/cff/cffgload.h
+++ b/src/cff/cffgload.h
@@ -29,7 +29,12 @@ FT_BEGIN_HEADER
#define CFF_MAX_OPERANDS 48
-#define CFF_MAX_SUBRS_CALLS 32
+#define CFF_MAX_SUBRS_CALLS 16 /* maximum subroutine nesting; */
+ /* only 10 are allowed but there exist */
+ /* fonts like `HiraKakuProN-W3.ttf' */
+ /* (Hiragino Kaku Gothic ProN W3; */
+ /* 8.2d6e1; 2014-12-19) that exceed */
+ /* this limit */
#define CFF_MAX_TRANS_ELEMENTS 32