[post] Fix bound checking
This commit is contained in:
parent
7ec694ddf2
commit
64f0becd89
|
@ -124,7 +124,7 @@ struct post
|
||||||
pool = &StructAfter<uint8_t> (v2.glyphNameIndex);
|
pool = &StructAfter<uint8_t> (v2.glyphNameIndex);
|
||||||
|
|
||||||
const uint8_t *end = (uint8_t *) table + table_length;
|
const uint8_t *end = (uint8_t *) table + table_length;
|
||||||
for (const uint8_t *data = pool; data < end && data + *data <= end; data += 1 + *data)
|
for (const uint8_t *data = pool; data < end && data + *data < end; data += 1 + *data)
|
||||||
index_to_offset.push (data - pool);
|
index_to_offset.push (data - pool);
|
||||||
}
|
}
|
||||||
inline void fini (void)
|
inline void fini (void)
|
||||||
|
|
Loading…
Reference in New Issue