[pshinter] Avoid unnecessary zeroing.
* src/pshinter/pshalgo.c (psh_hint_table_init,psh_glyph_init, psh_glyph_interpolate_normal_points): Use FT_QNEW_ARRAY.
This commit is contained in:
parent
99a940f84a
commit
0b635b1eb2
|
@ -182,9 +182,9 @@
|
||||||
count = hints->num_hints;
|
count = hints->num_hints;
|
||||||
|
|
||||||
/* allocate our tables */
|
/* allocate our tables */
|
||||||
if ( FT_NEW_ARRAY( table->sort, 2 * count ) ||
|
if ( FT_QNEW_ARRAY( table->sort, 2 * count ) ||
|
||||||
FT_NEW_ARRAY( table->hints, count ) ||
|
FT_QNEW_ARRAY( table->hints, count ) ||
|
||||||
FT_NEW_ARRAY( table->zones, 2 * count + 1 ) )
|
FT_QNEW_ARRAY( table->zones, 2 * count + 1 ) )
|
||||||
goto Exit;
|
goto Exit;
|
||||||
|
|
||||||
table->max_hints = count;
|
table->max_hints = count;
|
||||||
|
@ -1167,8 +1167,8 @@
|
||||||
memory = glyph->memory = globals->memory;
|
memory = glyph->memory = globals->memory;
|
||||||
|
|
||||||
/* allocate and setup points + contours arrays */
|
/* allocate and setup points + contours arrays */
|
||||||
if ( FT_NEW_ARRAY( glyph->points, outline->n_points ) ||
|
if ( FT_QNEW_ARRAY( glyph->points, outline->n_points ) ||
|
||||||
FT_NEW_ARRAY( glyph->contours, outline->n_contours ) )
|
FT_QNEW_ARRAY( glyph->contours, outline->n_contours ) )
|
||||||
goto Exit;
|
goto Exit;
|
||||||
|
|
||||||
glyph->num_points = (FT_UInt)outline->n_points;
|
glyph->num_points = (FT_UInt)outline->n_points;
|
||||||
|
@ -1797,7 +1797,7 @@
|
||||||
FT_Error error;
|
FT_Error error;
|
||||||
|
|
||||||
|
|
||||||
if ( FT_NEW_ARRAY( strongs, num_strongs ) )
|
if ( FT_QNEW_ARRAY( strongs, num_strongs ) )
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue