[morx/kerx] Limit range to subtable when sanitizing
This commit is contained in:
parent
a9fe787a11
commit
758c9d68e2
|
@ -953,10 +953,12 @@ struct KerxTable
|
|||
unsigned int count = thiz()->tableCount;
|
||||
for (unsigned int i = 0; i < count; i++)
|
||||
{
|
||||
c->set_object (*st);
|
||||
if (unlikely (!st->sanitize (c)))
|
||||
return_trace (false);
|
||||
st = &StructAfter<SubTable> (*st);
|
||||
}
|
||||
c->reset_object ();
|
||||
|
||||
return_trace (true);
|
||||
}
|
||||
|
|
|
@ -1061,10 +1061,12 @@ struct Chain
|
|||
unsigned int count = subtableCount;
|
||||
for (unsigned int i = 0; i < count; i++)
|
||||
{
|
||||
c->set_object (*subtable);
|
||||
if (!subtable->sanitize (c))
|
||||
return_trace (false);
|
||||
subtable = &StructAfter<ChainSubtable<Types> > (*subtable);
|
||||
}
|
||||
c->reset_object ();
|
||||
|
||||
return_trace (true);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue