diff --git a/c/makeotf/makeotf_lib/build/hotpccts/featgram.g b/c/makeotf/makeotf_lib/build/hotpccts/featgram.g index 4e0ee0306..bb491cb23 100644 --- a/c/makeotf/makeotf_lib/build/hotpccts/featgram.g +++ b/c/makeotf/makeotf_lib/build/hotpccts/featgram.g @@ -1934,7 +1934,7 @@ table_OS_2 ( <> ( - numUInt16>[valUInt16] <> + numUInt16>[valUInt16] <> )+ <> ) @@ -1943,7 +1943,7 @@ table_OS_2 ( <> ( - numUInt16>[valUInt16] <> + numUInt16>[valUInt16] <> )+ <> ) diff --git a/c/makeotf/makeotf_lib/source/hotconv/featgram.c b/c/makeotf/makeotf_lib/source/hotconv/featgram.c index 0aeea10bf..460874486 100644 --- a/c/makeotf/makeotf_lib/source/hotconv/featgram.c +++ b/c/makeotf/makeotf_lib/source/hotconv/featgram.c @@ -4502,7 +4502,7 @@ table_OS_2() do { valUInt16 = numUInt16(); - if ((arrayIndex) < kLenUnicodeList) unicodeRangeList[arrayIndex] = valUInt16; + if (arrayIndex < kLenUnicodeList) unicodeRangeList[arrayIndex] = valUInt16; arrayIndex++; zzLOOP(zztasp5); } while ((LA(1) == T_NUM)); @@ -4531,7 +4531,7 @@ table_OS_2() do { valUInt16 = numUInt16(); - codePageList[arrayIndex] = valUInt16; + if (arrayIndex < kLenCodePageList) codePageList[arrayIndex] = valUInt16; arrayIndex++; zzLOOP(zztasp5); } while ((LA(1) == T_NUM)); diff --git a/c/makeotf/makeotf_lib/source/typecomp/recode.c b/c/makeotf/makeotf_lib/source/typecomp/recode.c index 6000917f7..fcddf9bc6 100644 --- a/c/makeotf/makeotf_lib/source/typecomp/recode.c +++ b/c/makeotf/makeotf_lib/source/typecomp/recode.c @@ -4622,11 +4622,11 @@ void InitStaticFontData(tcCtx g, int font__serif_selector, double *StdVW, double /* are the same for all masters, in all the fill-in fonts. */ gi = cffGetGlyphInfo(ctx, h->newGlyph.fill_in_cff[font_index].scaling_gid, h->metricsPathcb); - cffFree(ctx); - scaling_gid_bottom = gi->bbox.bottom; scaling_gid_top = gi->bbox.top; + cffFree(ctx); + /* Now get the font transform matrix and the UDV to be used with */ /* this master face of the target font, for the new glyph from the */ /* fill-in MM font. Note that we are stepping through the master */