[subset] fix heap buffer overflow found by fuzzer.

This commit is contained in:
Garret Rieger authored and Behdad Esfahbod committed 2021-02-16 12:43:02 -07:00
1 parent ae860db893
commit 5ca353a2d0
3 files changed
+3

No files matched your search

+3
View File
@@ -2064,6 +2064,9 @@ struct LigatureArray : OffsetListOf<LigatureAttach>
unsigned ligature_count = 0;
for (hb_codepoint_t gid : coverage)
{
if (ligature_count >= this->len)
break;
ligature_count++;
if (!glyphset.has (gid)) continue;