mirror of
https://github.com/harfbuzz/harfbuzz.git
synced 2025-04-15 01:18:13 +00:00
[subset/cff1] Reuse a function
This commit is contained in:
parent
ffd23d3a31
commit
bd3e78770e
1 changed files with 2 additions and 2 deletions
|
@ -529,7 +529,7 @@ struct Charset
|
|||
|
||||
case 1:
|
||||
{
|
||||
Charset1 *fmt1 = c->allocate_size<Charset1> (Charset1::min_size + Charset1_Range::static_size * sid_ranges.length, false);
|
||||
Charset1 *fmt1 = c->allocate_size<Charset1> (Charset1::get_size_for_ranges (sid_ranges.length), false);
|
||||
if (unlikely (!fmt1)) return_trace (false);
|
||||
hb_codepoint_t all_glyphs = 0;
|
||||
for (unsigned int i = 0; i < sid_ranges.length; i++)
|
||||
|
@ -546,7 +546,7 @@ struct Charset
|
|||
|
||||
case 2:
|
||||
{
|
||||
Charset2 *fmt2 = c->allocate_size<Charset2> (Charset2::min_size + Charset2_Range::static_size * sid_ranges.length, false);
|
||||
Charset2 *fmt2 = c->allocate_size<Charset2> (Charset2::get_size_for_ranges (sid_ranges.length), false);
|
||||
if (unlikely (!fmt2)) return_trace (false);
|
||||
hb_codepoint_t all_glyphs = 0;
|
||||
for (unsigned int i = 0; i < sid_ranges.length; i++)
|
||||
|
|
Loading…
Add table
Reference in a new issue