[color/COLR] Fix bad sanitize

Bad bad bad bad code. Don't do that. If compiler's not happy, understand why.
This commit is contained in:
Behdad Esfahbod 2018-03-14 16:08:12 +01:00
parent 399c800b93
commit 150c53ee96
1 changed files with 2 additions and 2 deletions

View File

@ -80,8 +80,8 @@ struct COLR
{
TRACE_SANITIZE (this);
if (!(c->check_struct (this) &&
c->check_array ((const void*) &layerRecordsOffsetZ, sizeof (LayerRecord), numLayerRecords) &&
c->check_array ((const void*) &baseGlyphRecordsZ, sizeof (BaseGlyphRecord), numBaseGlyphRecords)))
c->check_array (&(this+layerRecordsOffsetZ), sizeof (LayerRecord), numLayerRecords) &&
c->check_array (&(this+baseGlyphRecordsZ), sizeof (BaseGlyphRecord), numBaseGlyphRecords)))
return_trace (false);
const BaseGlyphRecord* base_glyph_records = &baseGlyphRecordsZ (this);