unsigned glyph_count = hb_face_get_glyph_count (face);
for (hb_codepoint_t gid = 0; gid < glyph_count; ++gid)
{
- unsigned int num_layers = hb_ot_color_glyph_get_layers (face, gid, 0, NULL, NULL);
+ unsigned int num_layers = hb_ot_color_glyph_get_layers (face, gid, 0, nullptr, nullptr);
if (!num_layers)
continue;
unsigned int palette_count = hb_ot_color_palette_get_count (face);
for (unsigned int palette = 0; palette < palette_count; palette++)
{
- unsigned int num_colors = hb_ot_color_palette_get_colors (face, palette, 0, NULL, NULL);
+ unsigned int num_colors = hb_ot_color_palette_get_colors (face, palette, 0, nullptr, nullptr);
if (!num_colors)
continue;
FILE *font_name_file = fopen ("out/.dumped_font_name", "r");
- if (font_name_file != NULL)
+ if (font_name_file != nullptr)
{
fprintf (stderr, "Purge or move ./out folder in order to run a new dump\n");
exit (1);
}
font_name_file = fopen ("out/.dumped_font_name", "w");
- if (font_name_file == NULL)
+ if (font_name_file == nullptr)
{
fprintf (stderr, "./out is not accessible as a folder, create it please\n");
exit (1);
extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
{
hb_blob_t *blob = hb_blob_create ((const char *)data, size,
- HB_MEMORY_MODE_READONLY, NULL, NULL);
+ HB_MEMORY_MODE_READONLY, nullptr, nullptr);
hb_face_t *face = hb_face_create (blob, 0);
hb_font_t *font = hb_font_create (face);
hb_ot_font_set_funcs (font);
hb_buffer_t *buffer = hb_buffer_create ();
hb_buffer_add_utf8 (buffer, text, -1, 0, -1);
hb_buffer_guess_segment_properties (buffer);
- hb_shape (font, buffer, NULL, 0);
+ hb_shape (font, buffer, nullptr, 0);
hb_buffer_destroy (buffer);
}
hb_buffer_t *buffer = hb_buffer_create ();
hb_buffer_add_utf32 (buffer, text32, sizeof (text32) / sizeof (text32[0]), 0, -1);
hb_buffer_guess_segment_properties (buffer);
- hb_shape (font, buffer, NULL, 0);
+ hb_shape (font, buffer, nullptr, 0);
hb_buffer_destroy (buffer);
/* Misc calls on face. */
extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
{
hb_blob_t *blob = hb_blob_create ((const char *)data, size,
- HB_MEMORY_MODE_READONLY, NULL, NULL);
+ HB_MEMORY_MODE_READONLY, nullptr, nullptr);
hb_face_t *face = hb_face_create (blob, 0);
/* Just test this API here quickly. */
else
hb_set_del (drop_tables, tag);
- s = strtok(NULL, ", ");
+ s = strtok(nullptr, ", ");
}
return true;