[subset] don't visit lookup if covered glyph set has failed.

If covered glyph set is in error then the same lookup can be recursed into repeatedly potentially causing a fuzzer timeout. Fixes: https://oss-fuzz.com/testcase-detail/5416421032067072.
pull/2938/head
Garret Rieger 4 years ago committed by Behdad Esfahbod
parent 4ec18c85e6
commit 64122b5a44
  1. 2
      src/hb-ot-layout-gsubgpos.hh
  2. BIN
      test/fuzzing/fonts/clusterfuzz-testcase-minimized-hb-subset-fuzzer-5416421032067072

@ -120,6 +120,8 @@ struct hb_closure_context_t :
}
hb_set_t *covered_glyph_set = done_lookups_glyph_set->get (lookup_index);
if (covered_glyph_set->in_error ())
return true;
if (parent_active_glyphs ()->is_subset (covered_glyph_set))
return true;

Loading…
Cancel
Save