[HarfBuzz] harfbuzz: Branch 'master'

Behdad Esfahbod behdad at kemper.freedesktop.org
Tue Oct 16 02:47:44 UTC 2018


 src/hb-ot-color-cbdt-table.hh |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

New commits:
commit 4c27da7638f6d072c3ff93223488c4ab316236c1
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Mon Oct 15 19:46:45 2018 -0700

    [CBDT] Fix more offsetting
    
    Fixes https://oss-fuzz.com/v2/testcase-detail/5750379279548416

diff --git a/src/hb-ot-color-cbdt-table.hh b/src/hb-ot-color-cbdt-table.hh
index 30459684..1e1fe095 100644
--- a/src/hb-ot-color-cbdt-table.hh
+++ b/src/hb-ot-color-cbdt-table.hh
@@ -209,9 +209,10 @@ struct IndexSubtableRecord
 		  offsetToSubtable.sanitize (c, base, lastGlyphIndex - firstGlyphIndex + 1));
   }
 
-  inline bool get_extents (hb_glyph_extents_t *extents) const
+  inline bool get_extents (hb_glyph_extents_t *extents,
+			   const void *base) const
   {
-    return (this+offsetToSubtable).get_extents (extents);
+    return (base+offsetToSubtable).get_extents (extents);
   }
 
   bool get_image_data (unsigned int  gid,
@@ -420,7 +421,7 @@ struct CBDT
       if (!subtable_record || !x_ppem || !y_ppem)
 	return false;
 
-      if (subtable_record->get_extents (extents))
+      if (subtable_record->get_extents (extents, base))
 	return true;
 
       unsigned int image_offset = 0, image_length = 0, image_format = 0;


More information about the HarfBuzz mailing list