[kerx] Protect against stack underflow

Fixes https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=11367
This commit is contained in:
Behdad Esfahbod 2018-11-12 13:01:22 -05:00
parent 3e284e02c2
commit a549aa14a0
2 changed files with 1 additions and 1 deletions

View File

@ -260,7 +260,7 @@ struct KerxSubTableFormat1
depth = 0; /* Probably not what CoreText does, but better? */ depth = 0; /* Probably not what CoreText does, but better? */
} }
if (Format1EntryT::performAction (entry)) if (depth && Format1EntryT::performAction (entry))
{ {
unsigned int tuple_count = MAX (1u, table->header.tuple_count ()); unsigned int tuple_count = MAX (1u, table->header.tuple_count ());