* src/psaux/psobjs.c (ps_tofixedarray, ps_tocoordarray): Fix exit

logic.
(ps_parser_load_field) <T1_FIELD_TYPE_BBOX>: Skip delimiters
correctly.
(ps_parser_load_field_table): Use `fields->array_max' instead of
T1_MAX_TABLE_ELEMENTS to limit the number of arguments.
This commit is contained in:
Werner Lemberg 2007-06-18 07:07:55 +00:00
parent be183ebb5d
commit f48aec7b1e
2 changed files with 18 additions and 9 deletions

View File

@ -1,3 +1,12 @@
2006-06-18 Werner Lemberg <wl@gnu.org>
* src/psaux/psobjs.c (ps_tofixedarray, ps_tocoordarray): Fix exit
logic.
(ps_parser_load_field) <T1_FIELD_TYPE_BBOX>: Skip delimiters
correctly.
(ps_parser_load_field_table): Use `fields->array_max' instead of
T1_MAX_TABLE_ELEMENTS to limit the number of arguments.
2006-06-17 Werner Lemberg <wl@gnu.org>
* src/tools/ftrandom.c (font_size): New global variable.

View File

@ -803,9 +803,6 @@
if ( cur >= limit )
goto Exit;
if ( coords != NULL && count >= max_coords )
break;
if ( *cur == ender )
{
cur++;
@ -814,6 +811,9 @@
old_cur = cur;
if ( coords != NULL && count >= max_coords )
break;
/* call PS_Conv_ToFixed() even if coords == NULL */
/* to properly parse number at `cur' */
*( coords != NULL ? &coords[count] : &dummy ) =
@ -881,9 +881,6 @@
if ( cur >= limit )
goto Exit;
if ( values != NULL && count >= max_values )
break;
if ( *cur == ender )
{
cur++;
@ -892,6 +889,9 @@
old_cur = cur;
if ( values != NULL && count >= max_values )
break;
/* call PS_Conv_ToFixed() even if coords == NULL */
/* to properly parse number at `cur' */
*( values != NULL ? &values[count] : &dummy ) =
@ -1182,7 +1182,7 @@
FT_Int result;
result = ps_tofixedarray( &token.start, token.limit, 4, temp, 0 );
result = ps_tofixedarray( &cur, limit, 4, temp, 0 );
if ( result < 0 )
{
@ -1254,8 +1254,8 @@
error = PSaux_Err_Ignore;
goto Exit;
}
if ( num_elements > T1_MAX_TABLE_ELEMENTS )
num_elements = T1_MAX_TABLE_ELEMENTS;
if ( (FT_UInt)num_elements > field->array_max )
num_elements = field->array_max;
old_cursor = parser->cursor;
old_limit = parser->limit;