freetype-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Git][freetype/freetype][master] * src/sfnt/ttpost.c (load_format_{20,25


From: Alexei Podtelezhnikov (@apodtele)
Subject: [Git][freetype/freetype][master] * src/sfnt/ttpost.c (load_format_{20,25}): Tweak allocaton macros.
Date: Sat, 01 May 2021 16:25:18 +0000

Alexei Podtelezhnikov pushed to branch master at FreeType / FreeType

Commits:

2 changed files:

Changes:

  • ChangeLog
    1
    +2021-05-01  Alexei Podtelezhnikov  <apodtele@gmail.com>
    
    2
    +
    
    3
    +	* src/sfnt/ttpost.c (load_format_{20,25}): Tweak allocaton macros.
    
    4
    +
    
    1 5
     2021-05-01  Alexei Podtelezhnikov  <apodtele@gmail.com>
    
    2 6
     
    
    3 7
     	* src/sfnt/pngshim.c (Load_SBit_Png): Tweak allocaton macro.
    

  • src/sfnt/ttpost.c
    ... ... @@ -190,8 +190,8 @@
    190 190
           FT_Int  n;
    
    191 191
     
    
    192 192
     
    
    193
    -      if ( FT_NEW_ARRAY ( glyph_indices, num_glyphs ) ||
    
    194
    -           FT_FRAME_ENTER( num_glyphs * 2L )          )
    
    193
    +      if ( FT_QNEW_ARRAY ( glyph_indices, num_glyphs ) ||
    
    194
    +           FT_FRAME_ENTER( num_glyphs * 2L )           )
    
    195 195
             goto Fail;
    
    196 196
     
    
    197 197
           for ( n = 0; n < num_glyphs; n++ )
    
    ... ... @@ -227,7 +227,7 @@
    227 227
           FT_UShort  n;
    
    228 228
     
    
    229 229
     
    
    230
    -      if ( FT_NEW_ARRAY( name_strings, num_names ) )
    
    230
    +      if ( FT_QNEW_ARRAY( name_strings, num_names ) )
    
    231 231
             goto Fail;
    
    232 232
     
    
    233 233
           for ( n = 0; n < num_names; n++ )
    
    ... ... @@ -259,8 +259,8 @@
    259 259
               len = (FT_UInt)FT_MAX( 0, d );
    
    260 260
             }
    
    261 261
     
    
    262
    -        if ( FT_NEW_ARRAY( name_strings[n], len + 1 ) ||
    
    263
    -             FT_STREAM_READ( name_strings[n], len   ) )
    
    262
    +        if ( FT_QNEW_ARRAY( name_strings[n], len + 1 ) ||
    
    263
    +             FT_STREAM_READ( name_strings[n], len    ) )
    
    264 264
               goto Fail1;
    
    265 265
     
    
    266 266
             name_strings[n][len] = '\0';
    
    ... ... @@ -273,7 +273,7 @@
    273 273
                        " using NULL names for gid %d - %d\n",
    
    274 274
                         n, num_names - 1 ));
    
    275 275
             for ( ; n < num_names; n++ )
    
    276
    -          if ( FT_NEW_ARRAY( name_strings[n], 1 ) )
    
    276
    +          if ( FT_QNEW_ARRAY( name_strings[n], 1 ) )
    
    277 277
                 goto Fail1;
    
    278 278
               else
    
    279 279
                 name_strings[n][0] = '\0';
    
    ... ... @@ -336,7 +336,7 @@
    336 336
           goto Exit;
    
    337 337
         }
    
    338 338
     
    
    339
    -    if ( FT_NEW_ARRAY( offset_table, num_glyphs )   ||
    
    339
    +    if ( FT_QNEW_ARRAY( offset_table, num_glyphs )  ||
    
    340 340
              FT_STREAM_READ( offset_table, num_glyphs ) )
    
    341 341
           goto Fail;
    
    342 342
     
    


  • reply via email to

    [Prev in Thread] Current Thread [Next in Thread]