diff --git a/ChangeLog b/ChangeLog index 6e90f76d7..511c8cc3e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2015-09-17 Werner Lemberg + + [type42] Fix memory leak (#45989). + + * src/type42/t42parse.c (t42_parse_charstrings): Allow only a single + `CharStrings' array. + 2015-09-17 Werner Lemberg [psaux] Fix memory leak (#45986). diff --git a/src/type42/t42parse.c b/src/type42/t42parse.c index ee77d8638..003b63ed7 100644 --- a/src/type42/t42parse.c +++ b/src/type42/t42parse.c @@ -841,6 +841,15 @@ /* initialize tables */ + /* contrary to Type1, we disallow multiple CharStrings arrays */ + if ( swap_table->init ) + { + FT_ERROR(( "t42_parse_charstrings:" + " only one CharStrings array allowed\n" )); + error = FT_THROW( Invalid_File_Format ); + goto Fail; + } + error = psaux->ps_table_funcs->init( code_table, loader->num_glyphs, memory );