Commit 71b617d8b701301801f91ed3e7f293d2404b400b

Werner Lemberg 2016-09-29T19:53:39

[ftfuzzer] Speed up. * src/tools/ftfuzzer/ftfuzzer.cc (LLVMFuzzerTestOneInput): Don't check for embedded bitmaps if we have a non-default instance.

diff --git a/ChangeLog b/ChangeLog
index 311168f..ce78d60 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2016-09-29  Werner Lemberg  <wl@gnu.org>
 
+	[ftfuzzer] Speed up.
+
+	* src/tools/ftfuzzer/ftfuzzer.cc (LLVMFuzzerTestOneInput): Don't
+	check for embedded bitmaps if we have a non-default instance.
+
+2016-09-29  Werner Lemberg  <wl@gnu.org>
+
 	[truetype] Disallow bitmap strokes for non-default instances.
 
 	Also speed up access of default instances if GX variations are
diff --git a/src/tools/ftfuzzer/ftfuzzer.cc b/src/tools/ftfuzzer/ftfuzzer.cc
index 90a36d0..79ad305 100644
--- a/src/tools/ftfuzzer/ftfuzzer.cc
+++ b/src/tools/ftfuzzer/ftfuzzer.cc
@@ -263,6 +263,10 @@
           }
           else
           {
+            // bitmap strokes are not active for glyph variations
+            if ( instance_index )
+              continue;
+
             if ( FT_Select_Size( face, fixed_sizes_index - 1 ) )
               continue;
             flags |= FT_LOAD_COLOR;