diff --git a/ChangeLog b/ChangeLog index 867c3bdc2..58ce2317f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2004-01-20 Werner Lemberg + + * src/type1/t1parse.c (T1_Get_Private_Dict): Skip exactly one + CR, LF, or CR/LF after `eexec'. + 2004-01-18 David Turner * src/sfnt/ttsbit.c: removed compiler warning @@ -31,7 +36,6 @@ introducing the new FT_ARRAY_COPY and FT_ARRAY_MOVE macros to make copying arrays easier - 2004-01-14 Werner Lemberg * src/cff/cffload.c (cff_font_load): Load charstrings_index earlier. diff --git a/src/type1/t1parse.c b/src/type1/t1parse.c index cc0c2f3d2..885d60a5a 100644 --- a/src/type1/t1parse.c +++ b/src/type1/t1parse.c @@ -356,8 +356,22 @@ parser->root.limit = parser->base_dict + parser->base_len; T1_Skip_PS_Token( parser ); - T1_Skip_Spaces ( parser ); cur = parser->root.cursor; + if ( *cur == '\r' ) + { + cur++; + if ( *cur == '\n' ) + cur++; + } + else if ( *cur == '\n' ) + cur++; + else + { + FT_ERROR(( "T1_Get_Private_Dict:" )); + FT_ERROR(( " `eexec' not properly terminated\n" )); + error = T1_Err_Invalid_File_Format; + goto Exit; + } size = (FT_Long)( parser->base_len - ( cur - parser->base_dict ) );